r/ProgrammerHumor • • Aug 26 '20

Python goes brrrr

Post image
59.2k Upvotes

789 comments sorted by

View all comments

Show parent comments

1

u/00PT Aug 26 '20

Aren't javascript objects all just dictionaries essentially? You may not be able to represent the values exactly, but I don't see why you couldn't just do something like this: "{x:1,y:2.7,foo:function(bar)}"

5

u/zedpowa Aug 26 '20

Because JSON can't encode JS functions for example