• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

LISP

 
Arjun Shastry
Ranch Hand
Posts: 1899
1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,
Has anybody here used LISP? Last few months, I am seeing LISP on many blogs/bookstores!! What are the typical areas in which LISP is mainly used? Advantages over Java/C++?
 
Ernest Friedman-Hill
author and iconoclast
Marshal
Pie
Posts: 24212
35
Chrome Eclipse IDE Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Lisp is a very neat language (we don't write LISP anymore, but rather just Lisp). There's virtually no difference between data and code, so you can -- and often do -- build programs in memory and execute them. Lisp is so flexible that you can use it to program in virtually any style: procedural, object-oriented, functional, generic. It's used in a lot of academic research, and in a broad range of real-world applications, especially things with strong academic ties like computer vision, machine learning, data mining, etc.
 
Arjun Shastry
Ranch Hand
Posts: 1899
1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thanks Ernest. Lisp looks interesting.In terms of performance, how is it compared to java/c++?
 
Javier Neira
Greenhorn
Posts: 5
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Well Lisps usually are dinamyc typed and like ruby, groovy and so on is slower than static typed langs like java.
On the other hand data is immutables and it "create" new data in memory in each function call.
But for example Clojure use persistent data structure to optimize data geneation and you can attach metadata with type hints for optimize the code
But remember: "Premature optimization is the root of all evil"
Lisp is one of the references of all new languages from python to ruby, scala and of course clojure (which is a dialect of lisp like arc or scheme) and can be used in
any type of apps, including enterprise although it shines in ai apps (for example this)
 
Henry Wong
author
Marshal
Pie
Posts: 21518
84
C++ Chrome Eclipse IDE Firefox Browser Java jQuery Linux VI Editor Windows
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

I remember when I was a freshman in college, Lisp was the language that my cousin, and a few other geeks, whom I looked up to, were using. It was also the defacto language for artificial intelligence, at the time, so that added to the cool factor too. I remember that I really wanted to learn it... and even started to read a book on it.

A year later, I signed up for an AI course, even though I was already overbooked. And was kinda disappointed when I found out that the language in use, was not Lisp, but was Prolog. The instructor was new, and liked Prolog. Luckily, I didn't drop the course, as admittingly, Prolog still remains one of my favorite languages to date.

Henry

 
Jesper de Jong
Java Cowboy
Saloon Keeper
Posts: 15495
43
Android IntelliJ IDE Java Scala Spring
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I had a course at university that used Scheme, which is a variant of Lisp.

If you're interested in Lisp, then have a look at Clojure, which is a Lisp-like language that runs on the JVM.
 
Ulf Dittmer
Rancher
Posts: 42968
73
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
What I don't get about Clojure is why it's not using either Lisp or Scheme syntax, but something else - "defn", square brackets for parameters, etc.
 
Javier Neira
Greenhorn
Posts: 5
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Ulf Dittmer wrote:What I don't get about Clojure is why it's not using either Lisp or Scheme syntax, but something else - "defn", square brackets for parameters, etc.


well Clojure was done like a new Lisp, without compatibiliies with previous dialects. it has direct syntax to create data structures like python or javascript ([1 2 3] for vectors, {:a 1 :b 2} for maps and #{:a :b :c} for sets and (1 2 3) for lists of course) and i think is a good improvement over Common Lisp or Scheme. F. e. params of a function is a vector.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic