Hacker News new | past | comments | ask | show | jobs | submit login
The Newbie Guide to Common Lisp (ghostopera.org)
92 points by lispm on June 25, 2012 | hide | past | favorite | 15 comments



I was first exposed to Lisp via AutoCad in 1989, but other than creating the most simple programs it has never made much sense as a language compared to BASIC and those using semi-colons.

Just last night, I read PG's explanation of Lisp in Hackers and Painters that Lisp's parentheses are there because a Lisp program is its own parse tree (I hope I got that right) and that this is what gives it its flavor.

That explanation is what I think was missing from the Lisp tutorials I used to read, and what is missing from the article. Showing a few examples of lisp programs shows how all those insipid parentheses are used, but doesn't explain why.

A lisp tutorial can't look like a semicolon language tutorial without ignoring what's most beneficial in the language. To understand lisp, I think grsping the computer science concepts matters to a degree that it doesn't in some other languages.


It is ten years old, but I put together a guide with LOTS of help from the Lisp community "Loving Lisp, or the Savvy Programmer's Secret Weapon" http://markwatson.com/opencontent/lisp_lic.htm


This is more a guide on how to get up and running using SBCL and Emacs, and less a guide on Common Lisp


Any experience using Emacs with "cl" (a package to add Common Lisp functionality to elisp)?

(Now that it has lexical scoping...)

I would rather avoid installing anything else than Emacs before I write the first program that must be efficient. Is cl good enough for that? Or should I go straight to SBCL or similar if I don't want to restrict myself to writing emacs packages?


If you're trying to learn Common Lisp, then no 'cl' is not sufficient. It ads a few CL features to Emacs lisp, but it isn't the same thing at all.

If you're just trying to write Emacs extensions, then it's a nice extension to the language which makes it slightly more tolerable.


I've used the CL package in Emacs (with the proviso that if you're using it to build an Emacs library, as I was, then you're supposed to restrict its use to compile time, which is weird and takes back most of the value). It doesn't make Emacs Lisp into anything much like Common Lisp. The two are very different languages. The CL extensions in Emacs are kind of useful if you already know CL, but they're also a strap-on and the result is predictably a monstrosity.

I think you'd be better off picking which of the two languages you're interested in and learning that.


Thanks, it's clear now. I was confused about the purpose of the cl package. Just checked the manual again and it is not misleading.

I think it was my wishful thinking as I was looking for something more concise than elisp's set functions.


As someone who is currently reading SICP, this is a great complement. Thanks for putting it together.


You realize that the code given in SICP is Scheme, not CL, right?


Emacs/Slime combo is how one writes any kind of Lisp code nowadays. I have Slime (swank, really) backends for CL, scheme, clojure, dylan, etc.


Not trying to thread dump, but I see more practicality from learning Clojure. You'll get a wealth of libraries and an active community to help you on your journey.

That said, if you want to learn CL for fun, that is understandable (heck, I did it myself after doing elisp years ago in grad school). I recommend 'Land Of Lisp' as a fun way to learn CL.


I find common lisp to be plenty practical, its libraries mostly satisfactory(restas/cl-redis/cl-closure-template make a good combo for playing with web development), and its community's frankness and no bullshit attitude are rather refreshing after spending some time in the land of the cool kids. Also these lists of success stories contain some impressive shit:

http://www.franz.com/success/ http://www.lispworks.com/success-stories/ http://wiki.alu.org/Industry%20Application

PS Land of lisp is an awesome book.


Also I'd recommend 'Practical Common Lisp'. It is very well written and goes straight to bread and butter topics like file i/o and web programming.


This article should direct the "Newbie" to the very comprehensive Wikipedia article.

http://en.wikipedia.org/wiki/Common_Lisp


I've found Vim + Slimv + SBCL an adequate development environment as a long time Vim user.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: