News for hackers. Stuff that matters.
Re:Why Lisp is Awesome by rntz on Wednesday January 06, 2010 @04:08PM (#1035763)
This isn't why Lisp is awesome. This is why Lisp was awesome, back 50 years ago. Every single one of these features has since been adopted by mainstream scripting languages. What still sets Lisp apart is its metalinguistic capability - macros (hygienic or not).
Re:Why Lisp is Awesome by lispm on Wednesday January 06, 2010 @05:57PM (#1036024)
but in one language?

The main difference between Lisp and most other languages out there is that Lisp has been designed for computing with symbolic data.

    (+ a b)  is a Lisp expression

    '(+ a b)  is Lisp data
This enables the easy manipulation and computation with symbolic expressions that stand for Lisp programs, algebra terms, theorems, logic expressions, rules, frames, music compositions, ... and many more.

Some languages have similar capabilities that can be used easily (Prolog, Mathematica, ...). Some have it in difficult variants, where one has to deal with complex representations. Others simply represent programs as strings and not more.

Re:Why Lisp is Awesome by ieure on Wednesday January 06, 2010 @04:28PM (#1035813)
I was specifically writing about features Lisp pioneered which other languages adopted. I think it's enlightening to understand the roots and history of things, and fint it amazing that such an old language pioneered so many fundamental constructs.

Perhaps by 2059, we'll have languages with macros and regular syntax.

Re:Why Lisp is Awesome by jodrellblank on Wednesday January 06, 2010 @08:49PM (#1036270)
> Perhaps by 2059, we'll have languages with macros and regular syntax.

Boo has macros ... http://boo.codehaus.org/Language+Guide (at the end, under 'advanced features'.

Re:Why Lisp is Awesome by lispm on Wednesday January 06, 2010 @09:01PM (#1036297)
C has macros.
Re:Why Lisp is Awesome by joevandyk on Wednesday January 06, 2010 @04:12PM (#1035775)
Why would adopting language X's features make X less awesome?
Re:Why Lisp is Awesome by apu on Wednesday January 06, 2010 @04:18PM (#1035788)
Because awesome is usually used in a relative sense -- something is awesome compared to other stuff.

The implicit other stuff is "everything else."

Re:Why Lisp is Awesome by lispm on Wednesday January 06, 2010 @06:13PM (#1036049)
You are making that up. Awesome is a description like 'green'.

    Yesterday we saw an awesome game.

    The sound of the new stereo is awesome.

    The view from that skyscraper is awesome.
If I compare something I'd say:

    Yesterday I saw the most awesome game.
etc.
Re:Why Lisp is Awesome by justinhj on Wednesday January 06, 2010 @06:20PM (#1036068)
Not really. Inspiring awe is a property based on when you see it. If you could demo an iphone to someone in 1970 it would be awesome; if you demo it to someone in 2015 it would be an old iphone.

Green is forever.

Re:Why Lisp is Awesome by lispm on Wednesday January 06, 2010 @06:46PM (#1036109)
a Porsche from 1970 is still awesome. There are many things that have timeless qualities. Every time I hear 'The Man Machine' from Kraftwerk I think how awesome it is.

'The Grand Canyon is awesome' - how does that depend on WHEN I see it. As long as there is a Grand Canyon, it is awesome. It is of no concern if there are things less or more awesome. The Grand Canyon is just 'awesome'.

Lisp has for some people also timeless qualities. One of these people is Alan Kay (of Smalltalk, Dynabook, etc.) fame. Check some day what Alan thinks about Lisp: http://bc.tech.coop/blog/060224.html

"Most people who graduate with CS degrees don't understand the significance of Lisp. Lisp is the most important idea in computer science."

Re:Why Lisp is Awesome by blasdel on Wednesday January 06, 2010 @07:37PM (#1036185)
I can not think of a more clearly terrible example than Geology!

The Grand Canyon is in no way exempt from time -- millions of years ago it was just another unremarkable course of the Colorado River, and millions of years from now it will have eroded to nothingness. The Himalayas used to be an unremarkable coastline, and the Appalachians hills were once taller than Everest is now.

Re:Why Lisp is Awesome by lispm on Wednesday January 06, 2010 @07:54PM (#1036208)
Awesome is an impression by a person that makes an observation. Millions ago the earth had no Grand Canyon (and thus could not be observed) and millions years ago there were no observers that could be impressed by something.

As long as there is a GRAND CANYON (a label for an observable geological feature given by man) the GRAND CANYON will be awesome. Your father found the Grand Canyon awesome and and your children will find it awesome, too. For us humans the Grand Canyon, as long it is there and as long we are there, is 'awesome'.

'Awesome' is an impression that humans have of something. It has nothing to do with geological timescales.

Re:Why Lisp is Awesome by jodrellblank on Wednesday January 06, 2010 @08:46PM (#1036267)
Unless there is an atomic spaceship war in a hundred years which scars the earth with canyons that size every few hundred miles. Then our grand children will not find "the Grand Canyon" awesome, they will find it "just another of those huge canyons that are everywhere and really boring".

Redwoods are awesome trees because of their size. If all other trees died out and Redwoods were the only tree, they wouldn't be awesome, they would be "normal tree size".

Unless you are high you don't go around being awe inspired by everyday things. Awesome is implicitly comparing with "everything else". Different things aren't awesome, but awesome things are different - but only while they are different.

> a Porsche from 1970 is still awesome

Not to me. A Veyron, now that's awesome. Spitfires are awesome, but only anachronistically - for their time and their reputation at the time - they don't hold a candle to a modern fighter.

Re:Why Lisp is Awesome by lispm on Wednesday January 06, 2010 @09:22PM (#1036325)
I find a lot of cars awesome. Because they ALL have the SAME qualities that I like: excellent design, fantastic engineering, etc.

Sure, there might be cars with less fantastic engineering, those I might not find awesome. But it says nothing about that there is only a single thing of a certain type that I can find awesome or that other things are less or more awesome. 'Just awesome' stands for it alone.

No, I don't find the Veyron awesome. That's just butt ugly.

These are awesome cars:

http://www.ausmotive.com/images/Porsche-917-01.jpg

Especially the one in the front.

Re:Why Lisp is Awesome by jamesbritt on Wednesday January 06, 2010 @06:27PM (#1036081)
First time I went to New Mexico I saw some Kachini dolls. They looked, well, awesome.

After a few days or so, I saw many, many more Kachina dolls, such that I could start seeing differences in quality. Those first ones I saw? They really weren't all that awesome. They were actually sort of crappy, once I saw some truly awesome handiwork.

Whether or not something inspires awe really does depend on previous experience.

Re:Why Lisp is Awesome by lispm on Wednesday January 06, 2010 @06:51PM (#1036113)
how are the Niagara falls less awesome on the 8.Jan 2010 compared to 7.Jan.2010?
Re:Why Lisp is Awesome by likpok on Wednesday January 06, 2010 @07:28PM (#1036175)
You are misunderstanding his point. Lisp used to be awesome because it implemented feature X. That is, show people feature X in Lisp, and they would be impressed because nothing else did X.

Now, everything does X. Showing someone Lisp doing X will get the response of 'So what?'. Therefore, Lisp is no longer awesome because of feature X.

Re:Why Lisp is Awesome by lispm on Wednesday January 06, 2010 @07:50PM (#1036202)
You are misunderstanding the original point. Lisp has certain qualities that are rare, designed in a special way and work together in special ways.

Almost none of the mainstream scripting languages uses simple code as data as Lisp does. Not Ruby. Not Python. Not PHP. Not JavaScript.

None of them have the roots in a meta-circular interpreter that fits on a page.

http://arcfn.com/2008/07/maxwells-equations-of-software-exam...

None of those allow me to write symbolic computations in a simple and straight forward way like I can do it in Lisp.

I find that awesome.

Re:Why Lisp is Awesome by likpok on Thursday January 07, 2010 @01:36AM (#1036626)
Which is different (entirely) from what the article was saying. It listed off several things which current languages do.

What (someone) up the chain was saying was exactly that. Lisp is interesting because of those things that it alone does. Not because it is capable of things that other languages do.

Re:Why Lisp is Awesome by blasdel on Wednesday January 06, 2010 @07:40PM (#1036191)
You're thinking way too small -- It's much more obvious if you'd use geological timescales to compare geological features.
Re:Why Lisp is Awesome by lispm on Wednesday January 06, 2010 @08:01PM (#1036217)
Why should I do that? I'm a human. I find things I see awesome. I find all large 'falls' awesome. If the thing wasn't there a million years ago, who cares? I wasn't there also. But I'm here and some thing in the world can be observed by me as awesome. There are things that I might not find awesome after some years and there are other things that I find awesome for many years. Even if it is superseded by some newer stuff. The original iPod (I have one) is still awesome. It is a design classic. Timeless.
Re:Why Lisp is Awesome by scott_s on Wednesday January 06, 2010 @05:40PM (#1035979)
Nitpick: "dyanmic programming" does not meant what you think it means. http://en.wikipedia.org/wiki/Dynamic_programming
Re:Why Lisp is Awesome by vicaya on Wednesday January 06, 2010 @06:06PM (#1036038)
Risking being downmodded, I'd say Lisp is too "low level" for many common problems, which is great if your domain is parser/compiler construction/transformation/combination. I have no problem with lisp syntax (I can even tolerate C++ templates :), but it (and most general purpose languages) feels less natural for many domain specific problems than languages catering to the domains.

A DSL family based on a flexible core (with a lispish intermediate language even) might be a viable approach.

In many situations, simplicity and restrictions (constraints) in DSLs is better than flexibility and expressiveness in a general purpose language, because it can offer new possibilities for domain specific optimizations due to domain specific constraints.

Just like new notations in math led to breakthroughs in many math branches, new syntax can bring new life to software in many specific domains.

The key to such systems seems to be making DSLs easy to build and optimize using a suite of common building blocks (human (cs people) friendly intermediate languages (like lisp as opposed to VM byte codes) and libraries.)

Re:Why Lisp is Awesome by lispm on Wednesday January 06, 2010 @06:08PM (#1036041)
That's why Lisp was called 'AI assembler'. Literally hundreds of higher-level languages have been implemented on top of Lisp. One of those has been integrated into Common Lisp: CLOS, a high-level object-oriented language for programming dynamic systems, with meta-programming capabilities.
Re:Why Lisp is Awesome by vicaya on Wednesday January 06, 2010 @07:06PM (#1036143)
Most of these "high-level" languages are more of "extensions" (CLOS certainly feels like an extension) or alternative lispish languages than bona fide DSLs with DS constraints (that can be used for DS optimizations). The S-expression syntax feels foreign/messy in many domains.
Re:Why Lisp is Awesome by lispm on Wednesday January 06, 2010 @07:22PM (#1036169)
Languages on top of Lisp can be all from extensions, to languages with their own syntax, parser, compiler, ...

Examples for "high-level" languages on top of Lisp:

Macsyma, Axiom, Refine, AP5, RacerPro, CycL, NESL, Reduce, PVS, the original ML, ...

For a Lisp-like example see PDDL (Planning Domain Definition Language):

    (define (domain hanoi-domain)
            (:requirements :equality)
            (:predicates (disk ?x) (smaller ?x ?y) (on ?x ?y) (clear ?x))
            (:action move-disk
             :parameters (?disk ?below-disk ?new-below-disk)
             :precondition (and (disk ?disk)
                                (smaller ?disk ?new-below-disk)
                                (not (= ?new-below-disk ?below-disk))
                                (not (= ?new-below-disk ?disk))
                                (not (= ?below-disk ?disk))
                                (on ?disk ?below-disk)
                                (clear ?disk)
                                (clear ?new-below-disk))
             :effect (and (clear ?below-disk)
                          (on ?disk ?new-below-disk)
                          (not (on ?disk ?below-disk))
                          (not (clear ?new-below-disk)))))
Tools like these are widely used in logistics domains, one of the domains where Lisp has been widely used. There is a competition between planning systems and PDDL is being used to describe the problems.

For a non-s-expression domain specific language on top of Lisp see for example PWGL. It uses a graphical language. Also Macsyma/Maxima, and many many many others.

Re:Why Lisp is Awesome by sokoloff on Wednesday January 06, 2010 @03:51PM (#1035723)
If anyone misses Geocities or myspace, look at this site in IE. I'm not sure what exactly the point of (seemingly) intentionally making your blog site readable in FF and outrageously hard to read in IE is...
Re:Why Lisp is Awesome by ieure on Wednesday January 06, 2010 @04:24PM (#1035803)
I got tired of fixing layouts in IE and decided it would be more fun to break it instead.
Re:Why Lisp is Awesome by sokoloff on Thursday January 07, 2010 @07:47AM (#1036937)
That's certainly one approach.

From the outside, my interpretation of that is "I don't value my own opinion enough to make it accessible to users of other extremely common browsers."

I assume you blog because you feel like you have something to say that's worth reading. Making that content inaccessible to a very large segment of the browsers/users in the world works contrary to that. (I do sympathize with the PITA factor.)

Re:Why Lisp is Awesome by manicolosi on Thursday January 07, 2010 @12:59AM (#1036588)
That's too bad. I'm stuck at work and wanted to read this.
Re:Why Lisp is Awesome by KirinDave on Wednesday January 06, 2010 @04:36PM (#1035832)
I think the point is clearly, "Fuck you, Internet Explorer." It's a sentiment many on the internet share.

I've got a few places where I simply block IE with stylesheets myself.

Re:Why Lisp is Awesome by l0stman on Wednesday January 06, 2010 @04:44PM (#1035857)
You're not a company man, aren't you? :)
Re:Why Lisp is Awesome by KirinDave on Wednesday January 06, 2010 @04:48PM (#1035864)
I am more loyal than the sycophants who make excuses for shitty products. IE8 is not a good product, and it should be treated like an ugly leper until it gets its act together.
Re:Why Lisp is Awesome by jordyhoyt on Wednesday January 06, 2010 @04:00PM (#1035741)
Seems entirely intentional...

  <!--[if IE]>
  <link rel="stylesheet" href="http://atomized.org/wp-content/themes/atomized2/ie.css type="text/css" media="screen">
  <![endif]-->
I find it pretty hilarious, myself. The site is quite nice in firefox, but I would have immediately turned away if I were using ie. He must be making some assumptions about his readers.
Re:Why Lisp is Awesome by chollida1 on Wednesday January 06, 2010 @06:20PM (#1036067)
I wasn't aware you could use const char pointers in switch statements.

switch (var) {

    case "foo":
        printf("foo block.");
        break;

    case "bar":
        printf("bar block.");
        break;

    default:
        printf("Default case")
}
Re:Why Lisp is Awesome by mbrubeck on Wednesday January 06, 2010 @07:21PM (#1036167)
You can't:

$ cat foo.c

    #include <stdio.h>
    main() {
        const char *foo = "bar";
        switch (foo) {
            case "foo":
                printf("foo\n");
        }
    }
$ gcc -pedantic -std=c99 foo.c -o foo

    foo.c: In function ‘main’:
    foo.c:4: error: switch quantity not an integer
    foo.c:5: error: case label does not reduce to an integer constant
Re:Why Lisp is Awesome by chollida1 on Thursday January 07, 2010 @11:46AM (#1037355)
Sorry to make you put in so much work.

I'm aware that you can't do this.

I guess my sarcasm didn't translate:)

Re:Why Lisp is Awesome by DrJokepu on Wednesday January 06, 2010 @03:49PM (#1035715)
Many of these features are actually quite common in other languages. For example, C# has lambdas, functions as first class objects, closures, dynamic programming, null coalescence etc. The real power of Lisp in my opinion is not the existence of these features but the way they perfectly fit into the S-Expression syntax.
Re:Why Lisp is Awesome by abstractbill on Wednesday January 06, 2010 @04:07PM (#1035762)
Right. Mainstream languages have been gradually evolving towards Lisp but until they adopt a simple uniform syntax they won't get real macros, which I think is the biggest difference between Lisp and other languages today.
Re:Why Lisp is Awesome by DrJokepu on Wednesday January 06, 2010 @04:14PM (#1035781)
I believe that appreciating Lisp's minimalistic, tree-like syntax requires a very mathematical way of thinking. Many (perhaps most) developers have a different way of thinking. There's nothing wrong with that, diversity is a good thing but because of that, I don't think that the S-Expression syntax will ever become "mainstream".
Re:Why Lisp is Awesome by abstractbill on Wednesday January 06, 2010 @04:22PM (#1035798)
I think I agree... I'm undecided though. I actually find JSON to be a positive development, and potentially a step in this direction (i.e. the fact that people now use javascript literal data syntax as a way of serializing general data, and the syntax has been written down somewhere quite carefully and is not too verbose or ugly - at least compared to something like xml). Who knows how far the mainstream will take this though...
Re:Why Lisp is Awesome by lispm on Wednesday January 06, 2010 @06:15PM (#1036058)
It is already.

XML is full of prefix, nested syntax.

Re:Why Lisp is Awesome by abstractbill on Wednesday January 06, 2010 @06:56PM (#1036129)
Yes, but nobody would seriously write a programming language that used XML for its syntax.
Re:Why Lisp is Awesome by lispm on Wednesday January 06, 2010 @07:09PM (#1036146)
So you say existing XML-based programming languages were 'written' by non-serious people?

'Water':

    <defmethod test_true source=required="ek_string"> 
     <try <if> source.<execute_string/>.<not/>   
                 <concat "Busted: "source/>.<print/>
               else “OK”
          </if>
    
       >
      <concat "Errored: " source/>.<print/>
     </try>
   </defmethod>
See also XSLT, XL, RuleML, ...
Re:Why Lisp is Awesome by abstractbill on Wednesday January 06, 2010 @08:17PM (#1036233)
So you say existing XML-based programming languages were 'written' by non-serious people?

Whether or not the people who wrote (sorry, I guess "designed" is the more appropriate word) these languages were serious, I do believe they are a dead-end.

Re:Why Lisp is Awesome by dmoney on Wednesday January 06, 2010 @11:04PM (#1036462)
I think a better word would be "outfix".
Re:Why Lisp is Awesome by yuan on Wednesday January 06, 2010 @04:25PM (#1035805)
The "switch statement" in C is closer to the CASE macro[1] in Lisp.

[1]: http://www.lispworks.com/documentation/HyperSpec/Body/m_case...

Re:Why Lisp is Awesome by clueless123 on Wednesday January 06, 2010 @03:15PM (#1035620)
For the longest time I've heard that "Lisp is awesome", but no reasons why and when I've asked why, the answer is usually, "you have to try it to see it"

This article is a pretty nice down to earth point by point explanation why list is so cool. My question is: is that it ? lambdas, data is code, dynamic programing.. I mean those features are cool, but could someone post some more clear examples of why lisp is awesome?

Re:Why Lisp is Awesome by asolove on Wednesday January 06, 2010 @03:21PM (#1035636)
See the HN-famous books "Structure and Interpretation of Computer Programs," "Paradigms of Artificial Intelligence Programming," and "On Lisp."

The claim is that Lisp is a language at a higher level of abstraction. You will have to study hard to be able to appreciate that level, but it cannot be explained in another way.

Imagine explaining Calculus to a high school Physics student. You're likely to get back: "But I can find the acceleration of an object by using normal algebra and subtracting its position at two different times!" Calculus is hard, its benefits are not clearly better than approximation or high school algebra until you reach a level at which you brain thinks of Calculus as fundamental and sees the old equations as merely derived, less-powerful versions.

Why would you expect a mind-expanding language to be any easier to explain?

Re:Why Lisp is Awesome by clueless123 on Wednesday January 06, 2010 @03:57PM (#1035732)
Dude... that is a very good analogy! point well taken.
Re:Why Lisp is Awesome by silentbicycle on Wednesday January 06, 2010 @07:28PM (#1036176)
Also, it's worth noting that all three books implement a subset of Prolog (in Lisp). Prolog is another language which sounds really bizarre, but can be incredibly powerful. It's less general purpose than Lisp, though - essentially, it works by searching for answers that fulfill all criteria you specify, backtracking to (lazily) generate alternative answers as needed. It's conceptually really cool, and is great for prototyping certain kinds of problems. Some of the literature is also quite good, particularly _The Art of Prolog_ by Sterling & Shapiro.
Re:Why Lisp is Awesome by cylinder714 on Wednesday January 06, 2010 @04:42PM (#1035847)
This isn't an enumerated list, obviously, but it piqued my interest in Lisp, among other things:

http://wiki.alu.org/RtL_Highlight_Film

Re:Why Lisp is Awesome by jodrellblank on Wednesday January 06, 2010 @05:15PM (#1035925)
http://www.defmacro.org/ramblings/lisp-ducati.html

http://www.defmacro.org/ramblings/lisp.html

"""What would you rather do? Learn 16 different languages and frameworks in order to do "simple" log-file and configuration-file processing? Or just buckle down, learn Lisp, and have all of these problems go away forever?"""

http://steve.yegge.googlepages.com/the-emacs-problem

Re:Why Lisp is Awesome by clueless123 on Thursday January 07, 2010 @02:53PM (#1037887)
The above article (http://www.defmacro.org/ramblings/lisp.html) is excellent ! Thank you very much for the link.
Re:Why Lisp is Awesome by d0m on Wednesday January 06, 2010 @04:18PM (#1035790)
Instead of cond, you can use a switch.. it makes it even more succinct. I don't know why this post is rated so high thought.. it's like a copy of the preface of any scheme book.
Re:Why Lisp is Awesome by Locke1689 on Wednesday January 06, 2010 @07:18PM (#1036160)
That switch statement doesn't work. You can't compare pointers(?) and string literals like that.
Re:Why Lisp is Awesome by wendroid on Wednesday January 06, 2010 @04:23PM (#1035799)
I'm not declaring the awesomeness or otherwise of Lisp but you're a shitty C coder :)