3
votes

For a school project (a free choice project), I was planning on working my way through SICP(Structure and Interpretation of Computer Programs) and learning Scheme. After that I want to create something interesting with it (also part of this project). However, from what I've read, Scheme might not be the best dialect to use for a project and it might instead be better to use Common Lisp. (https://stackguides.com/questions/108201/common-lisp-or-scheme). However, that would mean I could not use SICP to learn it?

I also considered the option of first learning Scheme and then Common Lisp, but apparently there are some 'subtle' difference which could be very hindering.

What would be the best choice? Simply learn Scheme and use it? Learn Scheme and then learn Common Lisp? Or skip Scheme (and SICP) and simply learn Common Lisp? Or is there an ever better option?

3
Check out Eli Barzilay's excellent answer to this SO question: stackoverflow.com/questions/1159208/… -- hopefully it'll convince you to go the Scheme route when reading through SICP!Michał Marczyk
Even if you want to use Common Lisp later, you'll find that 70% of what you learn will be applicable to programming in general, and 90% will be applicable to Common Lisp.mqp

3 Answers

4
votes

The differences between Common Lisp and Scheme are over-rated. They are there, and some are important, but for actual work you will not have any trouble learning one and then the other. When I was commonly writing both, I could switch between them with no problems.

If you plan to start with SICP, then I would start learning Scheme. If you plan to start with your project and decide that you need Common Lisp for it, then I would start learning Common Lisp. Learning the second dialect is very easy after that.


There are a couple of things to consider. The type of project is most important: Scheme is excellent for language design projects. If your project is an interpreter/compiler/parser/etc for a new, weird kind of language (or just language feature), then Scheme is ideal. On the other hand, Common Lisp is very powerful in areas where you need a lot of basic utilities already built-in, but don't know precisely what it is you are building ahead of time--you end up with a DSL most of the time. That's why it was so popular in artificial intelligence. (That's the kind of code that I used it for.)

Second is that PLT has a low-learning-curve Scheme IDE called DrScheme. Common Lisp has a high-learning-curve Emacs plugin called Slime. In my experience, Slime is more powerful, but there is enough learning required that you should probably take it into account if this is a semester-long project (especially if you don't already use Emacs).

1
votes

SICP is a relatively old book and uses and older variant of Scheme. There are mostly only basic Scheme features used in the book. So, it is relatively easy to write solutions to the exercises in the book in Common Lisp. If you have some above averade skills, you should be able to translate the code to Common Lisp. Here is an example for SICP exercises in Common Lisp.

SICP is more a general book about programming and computer science, not so that much about Scheme or Lisp programming. For that, other books are better. For Common Lisp see 'Practical Common Lisp' as a good start.

0
votes

Once you have learned Scheme and worked through SICP, your programming ability in functional programming would be quite good.

At that time, learning Common Lisp would be easy. Do you think learning C# is a problem when you already know Java?