Content from 2012-09

Common Lisp Puzzle
posted on 2012-09-19 15:35:27
In the last week or so, a puzzle has shown up in one or two different places about a certain strange piece of Lisp code.  The code is as follows:
(let (#'1) (+ function 2))
==> 3

 

It took me a bit to figure out, but the trick is what reader macros expand to.  Also, where certain macros are in the code.

Don't have it yet?  I'll give you a hint:
(let ('1) (+ quote 2))
==> 3

This blog covers vegan, ice cream, Work, Vegan, Uncategorized, Rust, Resistance, Research, Repair, Recipes, Physics, Nest, Music, Lisp, Linux, Links, Link, Life, Language, Information, Image, Gnome, Games, Gallery, Food, Fascism, Esperanto, Emacs, Electronics, Education, Dog, Did You Know That?, DRM, Community, Comics, Colgate, Code, Buddhism, Books, Aside, Anarchism, 3D Printing

View content from 2009-04, 2009-06, 2009-07, 2009-08, 2009-10, 2009-11, 2009-12, 2010-05, 2010-06, 2010-07, 2010-08, 2010-09, 2011-01, 2011-02, 2011-03, 2011-04, 2011-06, 2011-07, 2011-08, 2011-09, 2011-10, 2011-11, 2011-12, 2012-01, 2012-02, 2012-03, 2012-04, 2012-07, 2012-08, 2012-09, 2012-11, 2013-02, 2013-03, 2013-04, 2013-06, 2013-07, 2013-09, 2013-11, 2014-01, 2014-02, 2014-03, 2014-07, 2014-11, 2014-12, 2015-01, 2015-02, 2015-07, 2015-10, 2015-11, 2015-12, 2016-01, 2016-05, 2016-08, 2016-10, 2016-11, 2016-12, 2017-02, 2017-06, 2018-04, 2019-03, 2009-03


Unless otherwise credited all material Creative Commons License by Matt Novenstern