5 ms·
Although I'm also skeptical of coding in JSON, s-expressions are pretty close to a JSON subset (with the caveat that everything needs to be quoted). (x . (y
by bijection 10y ago
Although I'm also skeptical of coding in JSON, s-expressions are pretty close to a JSON subset (with the caveat that everything needs to be quoted).
(x . (y . (z . NIL))) <=> ['x', ['y' , ['z', null]]]
- junke 10y agoThe first one is the flat list (x y z); the JSON one seems to be equivalent to (x (y (z nil))).
- bijection 10y agoYou're right! My scheme is rusty I guess. I should have said: (x . (y . (z . NIL))) <=> ['x', 'y', 'z']
- kazinator 10y agoIn Lisp, (x x x) denotes a list which contains three elements which are pointers to the same symbol object.