I am a college student who dream of being a great programmer some day. Now I am quite familiar with C, Perl, awk, shell programming , while not quite familiar with c++ and java. I installed linux on my PC and played happily with it, now reading books on UNIX system calls.
I was told that to be a good programmer, you must learn LISP, although you might never use it in your real life programming, it will teach you how to make good programs, is it true?
If so, where shall I start to learn LISP, Lisp interpreters does not seem to install in my LINUX system. But I guess that I shall be able to program lisp in Emacs, right?
could anyone give us some hints on starting to learn lisp???
<xu...@mercury.ee.cornell.edu> writes: > I am a college student who dream of being a great programmer some day. > Now I am quite familiar with C, Perl, awk, shell programming , while not > quite familiar with c++ and java. I installed linux on my PC and played > happily with it, now reading books on UNIX system calls.
> I was told that to be a good programmer, you must learn LISP, although > you might never use it in your real life programming, it will teach you > how to make good programs, is it true?
I can only speak for myself, but I have learnt much more about programming by learning Lisp. The things I have learnt by programming in Lisp also benefits my programming in other (lesser) languages. So even if you are unlucky and don't end up in a place where they do development in Lisp, you benefit by learning Lisp (as I see it). However, several places hire Lisp programmers, even in the Real Life, so I presume (and know) they use it in Real Life :-)
> If so, where shall I start to learn LISP, Lisp interpreters does not seem > to install in my LINUX system. But I guess that I shall be able to program > lisp in Emacs, right?
I would recommend, if you have previous programming experience, that you get hold of a good Lisp book (e.g Paul Graham's "ANSI Common Lisp" which I liked a lot) and get hold of a good Lisp environment suitable for learning. Luckily there are several good Lisp environments for Linux, where I tend to prefer Franz' Allegro Common Lisp which has a Trial Edition. Xanalys also has a nice environment in Lispworks. There also exist a few free (as in speech) Lisp compilers which can be used (CLISP, CMUCL, Poplog, ..).
> > I was told that to be a good programmer, you must learn LISP, although > > you might never use it in your real life programming, it will teach you > > how to make good programs, is it true?
Every additional computer language and programming paradigm you are exposed to makes you a better programmer, as you will slowly acquire different ways of thinking about problems.
> I would recommend, if you have previous programming experience, that > you get hold of a good Lisp book (e.g Paul Graham's "ANSI Common Lisp" > which I liked a lot)...
Isn't the Steele book the definitive text on Lisp? Anyway, it's probably the best reference manual.
Courageous <jkras...@san.rr.com> writes: > > I would recommend, if you have previous programming experience, that > > you get hold of a good Lisp book (e.g Paul Graham's "ANSI Common Lisp" > > which I liked a lot)...
> Isn't the Steele book the definitive text on Lisp? Anyway, it's > probably the best reference manual.
(I also have Steele (cltl2) as backup in case I need another explanation to back up the one in the HyperSpec, but I don't have the URL where I found it handy)
-- ------------------------------------------------------------------ Stig Erik Sandoe s...@ii.uib.no http://www.ii.uib.no/~stig/
* <xu...@mercury.ee.cornell.edu> | I was told that to be a good programmer, you must learn LISP, although | you might never use it in your real life programming, it will teach you | how to make good programs, is it true?
yes. "those who do not know Lisp are doomed to reinvent it."
| If so, where shall I start to learn LISP, Lisp interpreters does not seem | to install in my LINUX system.
that's odd. Linux systems are very well supported by Lisp systems. which Linux are you using? if you are using the programmers' favorite distribution, Debian GNU/Linux, you can install CLISP and CMUCL with the package system, and Franz Inc offers a trial edition for Linux that you basically download and install.
| But I guess that I shall be able to program lisp in Emacs, right?
you will, but Emacs Lisp is a _really_ ancient dialect of Lisp, with lots of interesting stuff missing. the modern Lisp is Common Lisp.
> I am a college student who dream of being a great programmer some day. > Now I am quite familiar with C, Perl, awk, shell programming , while not > quite familiar with c++ and java. I installed linux on my PC and played > happily with it, now reading books on UNIX system calls.
> I was told that to be a good programmer, you must learn LISP, although > you might never use it in your real life programming, it will teach you > how to make good programs, is it true?
IMO any programmer should learn a Lisp language. I would be happy if I started earlier really using it.
> If so, where shall I start to learn LISP, Lisp interpreters does not seem > to install in my LINUX system. But I guess that I shall be able to program > lisp in Emacs, right?
Strange, I installed CMUCL, have a Franz Allegro trial version running and installed Xanalys (was Harelequin) Lispworks. First the trial version and now the professional version.
System here Debian slink/potatoe, Kernel 2.2.15, glibc 2.1.2.
The following books have opened my eyes for the beauty of Lisp. Paul Norvigs Artificial Intelligence Programming and even move Grahams ON LISP.
I have to say that I don't like ANSI Common Lisp from Graham although it is recommended
More than Lisp, I would recommend learning as many languages as possible. In fact (and I will probably be shot at dawn for saying this on this group) I can see arguments for learning either Haskell (or ML) or Scheme before Lisp:
- Lisp is great because it supports so many different styles of programming. Recently I translated an interpreter for a small language from C to Lisp (the reason isn't important) and although the result was very ugly Lisp code it was not difficult to do. In other words (rather like moving from C to C++) you can continue programming "as you used to" without coming to understand the good bits of Lisp. Learning Haskell instead would protect you from yourself and force you to think about functional programming.
- A book that will probably improve your programming significantly is Abelson + Sussman's "Structure and Interpretation of Computer Programs". This is an acknowledged classic that uses Scheme. Scheme is a Lisp, historically, but these days it's treated as separate language. You might find that working through that book, with Scheme, is the best way to become a better programmer. If you take this route, however, I would strongly recommend returning to Common Lisp - Scheme is a very "slimmed down" version of Lisp and Common Lisp includes many many features that make programming more productive (someone else, Erik I think, said in another post that people "reinvent Lisp" - that's especially true of Scheme programmers, imho).
As for starting to program in Lisp - check out www.lisp.org for much useful info. Get both CLtL2 and the hyperspec in electronic form as references, if you can (links at www.lisp.org). Graham's book "On Lisp" is not intended for beginners, but I would suggest you try and read it as soon as you feel comfortable with the language.
I use CLISP which is in included in SuSE Linux - you can download binaries for most platforms from www.cons.org. Allegro give away a version of Lisp for Redhat (not Debian, afaik) and CMUCL is in Debian. More info at www.lisp.org. You can cross-install packages for different Linuxes (eg CMUCL is packaged for Debian, but you can install on other unixes) but it's not always trivial - ask Linux groups for specific details (the CLISP binaries are generic Linux, afaik, but you may need to check which C library you are using - maybe I'm the only dinosaur not running glibc these days).
Andrew
PS There's a sketchy review of programming languages on my web pages at www.andrewcooke.free-online.co.uk/index.html if you want further language recommendations (follow the link in the text).
PPS As a self-taught programmer (no CS degree) I understand what you mean about wanting to become a better programmer. The great thing is that you continue to improve and improve - either I'm a very slow learner or it just never stops :-)
<xu...@mercury.ee.cornell.edu> wrote: > I am a college student who dream of being a great programmer some day. > Now I am quite familiar with C, Perl, awk, shell programming , while not > quite familiar with c++ and java. I installed linux on my PC and played > happily with it, now reading books on UNIX system calls.
> I was told that to be a good programmer, you must learn LISP, although > you might never use it in your real life programming, it will teach you > how to make good programs, is it true?
> If so, where shall I start to learn LISP, Lisp interpreters does not seem > to install in my LINUX system. But I guess that I shall be able to program > lisp in Emacs, right?
> could anyone give us some hints on starting to learn lisp???
<xu...@mercury.ee.cornell.edu> writes: > I was told that to be a good programmer, you must learn LISP, although > you might never use it in your real life programming, it will teach you > how to make good programs, is it true?
More or less, yes.
Of course, I wouldn't say "must learn Lisp" but rather "is privileged by being able to learn Lisp."
Lisp is fun!
As for using Lisp, you will find a lot of prejudice against Lisp going around which might discourage you from using it for real life programming. However, this is mostly just prejudice and nothing more.
> If so, where shall I start to learn LISP, Lisp interpreters does not seem > to install in my LINUX system. But I guess that I shall be able to program > lisp in Emacs, right?
Don't use Emacs Lisp for anything but programming Emacs. It is an ancient and inferior Lisp.
> could anyone give us some hints on starting to learn lisp???
"Structure and Interpretation of Computer Programs" (SICP) by Abelson and Sussman with Sussman talks about programming in general, using examples in the Lisp variant Scheme. There are many implementations of Scheme for Linux. (scsh, guile, scm, stalin, ...)
Scheme is a _very_ small Lisp, suitable for learning, but not for much else. (In my opinion, of course) Some claim that when learning Lisp you should ignore Scheme and go right to Common Lisp. I think Scheme is worth learning, but only because SICP is a damn good book and you should have a Scheme system handy for trying out the examples and exercises.
"ANSI Common Lisp" by Graham is about modern Common Lisp, which is the Lisp to use for anything serious. It is a tutorial type book. There are many variants of Common Lisp, most of which works on Linux. Look at http://www.cons.org/, http://www.franz.com/ and http://www.harlequin.com/
"On Lisp" by Graham is a more advanced tutorial type book. I found the most interesting part of the book was about Lisp macros. Lisp has a macro system that is above and beyond _anything_ you can find in any other language. This book explains them and gives lots of examples. Some claim that it goes way too far in using macros.
On the reference side, the Hyperspec is it. This is a reworking of the official language standard into HTML and heavily cross-linked. It is really a wonder to behold and a joy to use.
"Paradigms of Artificial Intelligence Programming: Case Studies in Common Lisp" (PAIP) by Norvig is a _very_, _very_ good book. You should have read "ANSI Common Lisp" or a similar book first though.
The title of PAIP may seem daunting but don't let it stop you. The book is very readable, once you are able to read Lisp programs semi-fluently.
I just did a web search to get the title right, and found the following quote which I fully agree with:
I tell my students to think of Steele's book as the Oxford English Dictionary and Norvig's as the complete works of Shakespeare. - Prof. Wendy Lenhert (Massachusetts)
"Steele's book" in the above is "Common Lisp the Language". (CLtL) This a reference type book. Unfortunately it is out of date, so personally I use the Hyperspec only. (References need to be up to date)
CLtL has a few chapters that never made it into the ANSI standard. Some day I should read them.
If you have decided at this point that Lisp is your future main programming language, wether anybody pays you for it or not, you might want to look at "The Art of the Metaobject Protocol" (AMOP) by Kiczales, Rivieres and Bobrow.
There is also a book called "Lisp" by Winston and Horn which I have never read but which is often recommended by others.
On 25 Mar 2000 20:54:14 GMT, <xu...@mercury.ee.cornell.edu> wrote:
> I am a college student who dream of being a great programmer some day. [...] > I was told that to be a good programmer, you must learn LISP, although
``Lisp has jokingly been called "the most intelligent way to misuse a computer". I think that description is a great compliment because it transmits the full flavor of liberation: it has assisted a number of our most gifted fellow humans in thinking previously impossible thoughts.''
(from "The Humble Programmer", E. Dijikstra, CACM, vol. 15, n. 10, 1972, pag. 859)
> could anyone give us some hints on starting to learn lisp???
In article <ekv8zz6ghjw....@verden.pvv.ntnu.no> posted on Sunday, March 26, 2000 4:19 AM, Stig Hemmer <s...@verden.pvv.ntnu.no> wrote:
> CLtL has a few chapters that never made it into the ANSI standard. > Some day I should read them.
Interesting... which ones are they?
-- -> -\-=-=-=-=-=-=-=-=-=-/^\-=-=-=<*><*>=-=-=-/^\-=-=-=-=-=-=-=-=-=-/- <- -> -/-=-=-=-=-=-=-=-=-=/ { Rahul -<>- Jain } \=-=-=-=-=-=-=-=-=-\- <- -> -\- "I never could get the hang of Thursdays." - HHGTTG by DNA -/- <- -> -/- http://photino.sid.rice.edu/ -=- mailto:rahul-j...@usa.net -\- <- |--|--------|--------------|----|-------------|------|---------|-----|-| Version 11.423.999.210020101.23.50110101.042 (c)1996-2000, All rights reserved. Disclaimer available upon request.
Stig Hemmer <s...@verden.pvv.ntnu.no> writes: > "On Lisp" by Graham ... > "Paradigms of Artificial Intelligence Programming: Case Studies in > Common Lisp" (PAIP) by Norvig
On second thought: I think I recommend reading PAIP _before_ OL since this will make you more critical of OL. OL is good, but _should_ be read critically.
> I would recommend, if you have previous programming experience, that > you get hold of a good Lisp book (e.g Paul Graham's "ANSI Common Lisp" > which I liked a lot) and get hold of a good Lisp environment suitable for > learning. Luckily there are several good Lisp environments for Linux, > where I tend to prefer Franz' Allegro Common Lisp which has a Trial > Edition. Xanalys also has a nice environment in Lispworks. There > also exist a few free (as in speech) Lisp compilers which can be used > (CLISP, CMUCL, Poplog, ..). > (www.franz.com, www.xanalys.com, clisp.sourceforge.net, www.cons.org/cmucl)
Thanks for all the kindly replies. Now I had download CLisp from www.franz.com and installed it successfully. I also borrowed 3 books on Lisp,(Steele, Norvig,Abelson et al.)
Now I have all the stuff needed to get my hands dirty with Lisp. :) Any hints on how to learn Lisp effectively?
<xu...@mercury.ee.cornell.edu> wrote: > I also borrowed 3 books on Lisp,(Steele, Norvig,Abelson et al.)
> Now I have all the stuff needed to get my hands dirty with Lisp. :) > Any hints on how to learn Lisp effectively?
You can't go wrong with Norvig's book. Start with Parts I and III. Abelson et al. uses Scheme and not Common Lisp so it will be of limited value to learning Common Lisp. It is a great book though.
<xu...@mercury.ee.cornell.edu> wrote: > Now I have all the stuff needed to get my hands dirty with Lisp. :) > Any hints on how to learn Lisp effectively?
Think of a program you'd really like to write, then start to write it. Pester this group when you get stuck. Half way through, realise that you could do it a lot better given what you know by then. Throw it away and start a different problem/language that looks more interesting. Publish anything that you do complete on the net under the GPL. Iterate 'til you grow old and die.
xutao wrote: > I was told that to be a good programmer, you must learn LISP, although > you might never use it in your real life programming, it will teach you > how to make good programs, is it true?
I think this is an interesting way of looking at the world. Although lisp is `cool' (that is common lisp and this is in comparison to cool ;) I'm sure there are many other things that would make you (or me or whoever) a better programmer than simply learning to programme in lisp. Learning lisp is a good start tho'.
I feel that ideally you should learn at least one major language from each of the major forms, and even some things that aren't exactly really languages. My current selection would run (in no particular order): Lisp, FORTH, C, Ada95, OCaML, assembler, MS Excel macros
With this as a basis, there are options: Snobol, Eiffel.
And then the "hot" languages: Java, HTML, XML, MS Visual Basic, C++ {these are in what I think of as the appropriate order [N.B.: This list changes frequently!]}
That's ideal. That's also a multi-year program. Most folk pick a small selection from that on various bases (e.g., what's supported locally).
>> > I was told that to be a good programmer, you must learn LISP, although >> > you might never use it in your real life programming, it will teach you >> > how to make good programs, is it true?
>Every additional computer language and programming paradigm you >are exposed to makes you a better programmer, as you will slowly >acquire different ways of thinking about problems.
One reason I recommend Common Lisp is that it covers more paradigms than any other language I'm familiar with.
>Isn't the Steele book the definitive text on Lisp? Anyway, it's >probably the best reference manual.
It used to be the reference. It never was a good book to learn Lisp from. I have a copy, which is sometimes helpful, but I use the Hyperspec and the appendix of "ANSI Common Lisp" more often.
I have no good way of judging beginning Lisp books, since I've learned it in my own way over many years, but Graham's looks as good as any.
Charles Hixson <charleshi...@earthlink.net> wrote: > I feel that ideally you should learn at least one major language from each of > the major forms, and even some things that aren't exactly really languages. > My current selection would run (in no particular order): > Lisp, FORTH, C, Ada95, OCaML, assembler, MS Excel macros
I was a bit surprised to see MS Excel macros here - I've never used Excel, but will be installing it soon at work. Why did you include it? Are Excel macros something like SQL (ie could that last item have been Prolog or SQL?) (apologies to Prolog users ;-)?
Andrew Cooke wrote: > Think of a program you'd really like to write, then start to write it. > Pester this group when you get stuck. Half way through, realise that > you could do it a lot better given what you know by then. Throw it away > and start a different problem/language that looks more interesting. > Publish anything that you do complete on the net under the GPL. Iterate > 'til you grow old and die.
I'd like to take this a bit further.
Many programs require structuring, sorting and searching of data, and this can be done elegantly and efficiently in Lisp. But if one has a C-like programming background, the entire code/data structures are often constructed in a "conventional" manner, so that the underlying power of Lisp does not shine through.
I would like to emphasize the non-mechanical use of Common Lisp. By that I mean code that is not directly mappable, ie has no single simple relation to the data it manipulates.
To get a better feel of what can really be done with Lisp, you could choose some domain where applications are difficult to implement, or even demonstrate, in most conventional languages. Examples are planning, goal-searching, and simulation, which you will find in the books by Winston&Horn and Graham.
Such examples show the kind of thinking you must apply, before going to the keyboard. They also illustrate an earlier comment (by Erik Naggum, about reinventing Lisp), that with other languages, you must write a horrendous amount of utility routines before you can even start on your actual problem.
Paul Rudin <Paul_Ru...@scientia.com> wrote: > >>>>> "Andrew" == Andrew Cooke <and...@andrewcooke.free-online.co.uk> writes:
> Andrew> Are Excel macros something like SQL (ie could that last item > Andrew> have been Prolog or SQL?) (apologies to Prolog users ;-)?
> These day "Excel Macros" are VBA - "the most popular programming language in > the world" (and probably the worst too :-)).
Thanks. My post probably made more sense to the telepathic amongst you who realised I was confusing Excel and Access... (Access is the DB product, I think). Anyway, in that case, I guess I'd add Prolog to the original list (although I suppose once you've read almost any Lisp book you'll have met the basics - all three I've read (Norvig, A&S, On Lisp) seem to implement some kind of Prolog)
<xu...@mercury.ee.cornell.edu> writes: > I was told that to be a good programmer, you must learn LISP, although > you might never use it in your real life programming, it will teach you > how to make good programs, is it true?