I want to learn a functional programming language from the Lisp dialect but I'm not sure which one to pick. I want to be able to do practical things with it so I was thinking about Clojure. Does /prog/ have any suggestions?
Name:
Anonymous2011-09-06 23:02
Clojure is more complicated than Scheme, stemming from both its design goals, with a more complex syntax which often saves keystrokes, but which can sometimes confuse you, and some compromises that it made to run on the JVM, like its lack of proper TCO. Also, the stack traces are shit.
On the other hand, you get a crap load of Java libraries besides Clojure ones, but those are often an eyesore when used within Clojure code, even though it's common to find wrappers. Also, Emacs support is very good and there are plugins for other IDEs as well.
I'll let someone else comment on Racket, I can only say that the base libraries are pretty large, but the IDE is rather poor save for the debugger and I don't know about the third party packages (I know that fluxus is suffering from the constant changes in Racket).
Name:
Anonymous2011-09-06 23:11
if you want to learn Lisp, then go with CL or Scheme. Clojure is sort of a hybrid that experiments with non-lisp syntax (non-paranthesis). I would recommend Scala over Clojure by a long shot if you are already familiar with Java.
>>4
Probably because of all the higher order functions that you use in any Lisp dialect.
But anyway, as I didn't say it my previous post, I'll say it here: I would recommend the OP to go with Clojure anyway, because of the momentum which its community has garnered, and for forcing you for the most part to write purely functional code.
>>13
the "functional style" is highly practical, but it's hard to discover with C.
Name:
Anonymous2011-09-08 4:20
>>12
OP doesn't talk about Lisp in general, he talks about Clojure. It's much more functional than other Lisps (including Scheme), and almost as functional Haskell.
it tolerates a very non-functional style
Clojure doesn't. Collections are lazy and immutable in Clojure.
>>2
So would you say that Clojure is worth learning? I use CL and I was just looking at Clojure a little, there are a bunch of things I don't really like about it (Lisp-1, no TCO, minor annoyances like () evaluating to true) but it does have some neat features. I guess that it's biggest advantage (arguably) is that it runs on the JVM, isn't it?
There are many nice features in Clojure besides the ability to call Java libraries. Rich set of collections which are neatly integrated into the language and the concurrency machinery, for example.
Name:
Anonymous2011-09-09 17:06
Go with the original SICP Scheme, using the Chicken toolkit, includes libraries, c/c++ interfacing in-line, compiling, and many many other dialects if they use some sort of interpretation/compile flag.
>>28
So you would rather need a separate map function for each datatype?
Name:
Anonymous2011-09-09 18:17
>>29
That's not really what I'm talking about. I think conj is dangerous, because you really don't want to forget which structure you are modifying, for both performance and safety reasons.