Programming Designs Forums

Programming Designs

You are not logged in.

Announcement

This forum is for archival purposes only. Registration and posting have been disabled.

#1 2006-01-08 05:33 AM

VisionForce
Moderator
From: Tennessee, U.S.A.
Registered: 2006-01-08
Posts: 458
Website

LISP

Anyone here use LISP? I don't and I was wondering what it is for.


----
Alex C. Barberi
VisionForce
http://www.visionforceweb.com


"It's not who you say you are underneath, it's what you do that defines you."

Offline

 

2006-01-08 05:33 AM

Sponsors


#2 2006-01-08 11:38 AM

The_Maniac
Muhammad
From: Somewhere!!
Registered: 2005-11-26
Posts: 440
Website

Re: LISP

Heard about it once , but never seen it though
I'll research it


I hate it when I dunno sumthin'

sad


http://img15.imgspot.com/u/07/15/04/sig1168938835.jpg

Offline

 

#3 2006-01-08 12:37 PM

VisionForce
Moderator
From: Tennessee, U.S.A.
Registered: 2006-01-08
Posts: 458
Website

Re: LISP

Should I really post these things when I can find the answer? lol

Here's what I found:
LISP is an acronym for LISt Processing. Its development history has often been associated with symbolic processing and with both computer and human languages. Lisp has evolved into a family of languages. The two major dialects in use today are Common Lisp and Scheme.

Last edited by VisionForce (2006-01-08 12:38 PM)


"It's not who you say you are underneath, it's what you do that defines you."

Offline

 

#4 2006-01-08 12:46 PM

VisionForce
Moderator
From: Tennessee, U.S.A.
Registered: 2006-01-08
Posts: 458
Website

Re: LISP

Here is some lisp code I got from
http://lib.store.yahoo.net/lib/paulgraham/acl2.lisp


(defun compress (x)
  (if (consp x)
      (compr (car x) 1 (cdr x))
      x))

(defun compr (elt n lst)
  (if (null lst)
      (list (n-elts elt n))
      (let ((next (car lst)))
        (if (eql next elt)
            (compr elt (+ n 1) (cdr lst))
            (cons (n-elts elt n)
                  (compr next 1 (cdr lst)))))))

(defun n-elts (elt n)
  (if (> n 1)
      (list n elt)
      elt))


"It's not who you say you are underneath, it's what you do that defines you."

Offline

 

#5 2006-01-08 12:50 PM

The_Maniac
Muhammad
From: Somewhere!!
Registered: 2005-11-26
Posts: 440
Website

Re: LISP

is there anyone using this language? , cuz i dunno , that code looks weird

Are you planning to use it Vision??

:mrgreen:


http://img15.imgspot.com/u/07/15/04/sig1168938835.jpg

Offline

 

#6 2006-01-08 01:20 PM

VisionForce
Moderator
From: Tennessee, U.S.A.
Registered: 2006-01-08
Posts: 458
Website

Re: LISP

I want to learn it, but it looks like it's a Mac language... I'm not sure.


"It's not who you say you are underneath, it's what you do that defines you."

Offline

 

#7 2006-01-08 01:42 PM

The_Maniac
Muhammad
From: Somewhere!!
Registered: 2005-11-26
Posts: 440
Website

Re: LISP

What's the capabilities of this language??
If it's powerfull then I should have a look.


wink


http://img15.imgspot.com/u/07/15/04/sig1168938835.jpg

Offline

 

#8 2006-01-08 01:51 PM

VisionForce
Moderator
From: Tennessee, U.S.A.
Registered: 2006-01-08
Posts: 458
Website

Re: LISP

You can download free LISP compilers/IDEs at:
http://www.lisp.org/table/systems.htm

I'm looking up LISP's capabilities...


"It's not who you say you are underneath, it's what you do that defines you."

Offline

 

#9 2006-01-08 01:55 PM

VisionForce
Moderator
From: Tennessee, U.S.A.
Registered: 2006-01-08
Posts: 458
Website

Re: LISP


"It's not who you say you are underneath, it's what you do that defines you."

Offline

 

#10 2006-01-08 02:00 PM

The_Maniac
Muhammad
From: Somewhere!!
Registered: 2005-11-26
Posts: 440
Website

Re: LISP

Looking good , but not for me though , i don't even like java :mrgreen:
Visual Basic Rocks. big_smile


http://img15.imgspot.com/u/07/15/04/sig1168938835.jpg

Offline

 

#11 2006-01-08 05:11 PM

One-Up
Junior Member
Registered: 2005-12-19
Posts: 68

Re: LISP

I believe dreamvb would know something about this -- he is quite smart!

Offline

 

#12 2006-01-09 05:31 AM

The_Maniac
Muhammad
From: Somewhere!!
Registered: 2005-11-26
Posts: 440
Website

Re: LISP

No Comment

:roll:


http://img15.imgspot.com/u/07/15/04/sig1168938835.jpg

Offline

 

#13 2006-01-09 11:27 PM

dreamvb
Moderator
From: UK
Registered: 2005-10-01
Posts: 310

Re: LISP

I never used LISP my self but I did a little serach and found out this.

LISP, an acronym for list processing, is a programming language that was designed for easy manipulation of data strings. Developed in 1959 by John McCarthy, it is a commonly used language for artificial intelligence (AI) programming. It is one of the oldest programming languages still in relatively wide use.
In LISP, all computation is expressed as a function of at least one object. Objects can be other functions, data items (such as constants or variables), or data structures. LISP's ability to compute with symbolic expressions rather than numbers makes it convenient for AI applications.

I also found this link. gives some more information and some examples.

http://www.paulgraham.com/lisp.html


On error resume pulling hair out.

Offline

 

#14 2006-01-10 08:30 AM

Quantumstate-Jim
Moderator
From: UK
Registered: 2005-09-30
Posts: 684
Website

Re: LISP

The only place I've seen this is with plugin coding.  The syntax is very strange.


There are 10 types of people in this world.  Those that can read binary and those that can't.
www.quantumstate.co.uk
http://www.danasoft.com/sig/Quantumstate.jpg

Offline

 

#15 2006-01-11 03:19 AM

VisionForce
Moderator
From: Tennessee, U.S.A.
Registered: 2006-01-08
Posts: 458
Website

Re: LISP

The syntax is quite strange, that's what intrigues me about it. I would be interested in learning except for the fact that it look so complex and I'm really digging into VB.NET and the framework right now.


"It's not who you say you are underneath, it's what you do that defines you."

Offline

 

#16 2006-01-11 04:16 AM

The_Maniac
Muhammad
From: Somewhere!!
Registered: 2005-11-26
Posts: 440
Website

Re: LISP

sure , it's complicated but, if its use is greater than its difficulty, you should learn it.  :chinese:


http://img15.imgspot.com/u/07/15/04/sig1168938835.jpg

Offline

 

#17 2006-01-12 06:28 AM

VisionForce
Moderator
From: Tennessee, U.S.A.
Registered: 2006-01-08
Posts: 458
Website

Re: LISP

lol I have no use for it.


"It's not who you say you are underneath, it's what you do that defines you."

Offline

 

#18 2008-08-05 11:03 PM

dblanchard
New Member
Registered: 2008-08-05
Posts: 2

Re: LISP

Lisp is cool in a few ways, but the one that strikes most people is that everything is a list. Hence, it is a pretty good list processor. When the first element of a list is not escaped (quoted - described below), that element is read by the interpreter as a command. It doesn't become clear until you use it a while, but this means that you can treat Lisp code as a data structure. Now that's powerful.

Depending on the command, the interpreter will look for an embedded list, which may start with another command, or parameters, or arguments. It is very elegant this way, but not immediately intuitive. Once you learn a little syntax, you can do a great deal with it.

Some syntax notes:
A list is zero or more elements surrounded by parens.
Lists can contain sublists.
Lists are processed from the innermost list outward. If two or more lists are at the same level of embeddedness, they are processed right-to-left (I think - it hasn't ever mattered to me).
A command as the first element of a list will be processed as, yup, a command.

A few samples (colon represents the user prompt and the following line shows the interpreter's output:
: (+ 3 4)
7

: (+ 12 (* 2 6))
24

: (+ (* 3 4) (* 2 6))
24

: (* (+ 2 3 4) (* 2 3))
54

More syntax and examples:
A single quote before a list "quotes" the whole list.
:'(+ a b c)
(+ a b c)

Common predications end with 'p.'
: (integerp 2)
T

Top-level commands all start with colon, comments start with semi-colon:
: :res   ; resets the debugger
: :ld <file_name>    ; loads <file_name>
: :exit  ; exits the "listener"

I'm just getting started in Lisp (Common Lisp), and am learning to love it. Some really great books are written for Lisp and Scheme like "The Elements of AI: an Introduction Using Lisp" http://www.amazon.com/Elements-Artifici … amp;sr=8-1 and SICP http://mitpress.mit.edu/sicp/.

And, that is all I have time for tonight. There are already plenty of really good tutorials on Lisp. I suggest you give it a week or two and see if you like it.

D

Offline

 

Board footer

Powered by PunBB
© Copyright 2002–2005 Rickard Andersson