Slashdot Mirror


Lisp as an Alternative to Java

Joseph Dale writes "Lisp as an Alternative to Java is a detailed and well-reasoned study comparing Lisp to Java and C++ in terms of execution time, memory consumption, and developer effort. The author, Erann Gat, was the principal software architect for the Mars Science Microrover, the prototype for the Mars Pathfinder rover."

87 of 372 comments (clear)

  1. It's about the API by The+Ultimate+Badass · · Score: 4, Troll

    I don't care if LISP runs 500 times as fast as Java. It has a massively restricted API. People don't base their language choice on speed anymore. FORTRAN is still twice as fast as C, but everyone still uses C, for two reasons: FORTRAN is harder to learn, and C has more libraries.

    Java's great strength is that it has a huge set of APIs, all in a unified form, making programming a less repetitive and painful experience. Java is for people who understand that recoding the same search tree three hundred times is not going to make them richer, cooler or a better programmer. LISP is for people with time to waste.

    --

    Denial isn't just a river in Italy

    1. Re:It's about the API by lars_stefan_axelsson · · Score: 2, Interesting
      Well, all that repetition that you claim one must do to program in Lisp (Scheme in my case) should translate to longer development times, shouldn't it?

      Then how do you explain that the development times reported for Lisp were about half those of Java, comparing the median?

      --
      Stefan Axelsson
    2. Re:It's about the API by redhog · · Score: 5, Informative

      Nahnah. You haven't touched a LISP the last 20 years or so, have you? There's a popular LISP dialect called Scheme. It has a huge function library called slib, and there are bindings for a hell lot of C libraries for Scheme (it is also very easy to create new such bindings for most implementations of scheme).

      --
      --The knowledge that you are an idiot, is what distinguishes you from one.
    3. Re:It's about the API by gowen · · Score: 2
      Fortran is more difficult to read because the subroutine arguments are passed as pointers not by value.


      Thats true, but Fortran is mainly used in scientific computing, where arguments are often arrays, and frequently arrays of such size that passing them by anything other than reference is insane, not to mention undesirable.

      Well defined function names and documentation will tell a reader which functions modify which arguments, anyway.

      --
      Athletic Scholarships to universities make as much sense as academic scholarships to sports teams.
    4. Re:It's about the API by gawi · · Score: 5, Informative

      From what I've seen of SLIB, it is not comparable with the Java 2 platform (standard edition) version 1.4. :

      Threads

      I/O (blocking or non)

      Reflection API

      Weak references (and the likes)

      Networking (including http client, ipv6 support, URLs, datagrams, network interface)

      RPC (RMI, CORBA)

      Security (permission, keys)

      Relational database API (implemented by MANY vendors, you can often *choose* your implementation...)

      Text formatting

      Data structures (OK, needs functional improvements, I agree)

      Useful classes: date, calendar, locale, time zones, currency, timer...

      Logging

      Regexp

      Zip

      Preferences

      Accessibility

      Imaging API

      Naming API (directories, ldap)

      Printing API

      GUI API (awt, Swing)

      XML parser + DOM + SAX

      XSLT

      Components (java beans)

      Sound

      Should I continue with enterprise edition?

      I think no langage can compete with Java in terms of API richness and uniformity.

      --
      All humans are mortal. Socrates is a human. Socrates is dead.
    5. Re:It's about the API by jovlinger · · Score: 2

      I would be interested in how LISP and Scheme work in a team programming environment. I definitely agree that they are great languages for my own hacking, but am not sure how the almost fanatical flexibility would interact with teams.

      Or to ask the question in reverse: why did Dylan choose to move to a pseudo OO paradigm with optional type checking?

      I suspect the answer is that for larger projects, the skeleton/framework provided by a more static system allows some bugs to caught early, and in general acts to guide development.

      Has anyone used LISP/Scheme in a larger project?

    6. Re:It's about the API by Wavicle · · Score: 5, Insightful
      He was comparing apples to oranges near as I can tell. I can't actually read the original paper so it is kind of hard to tell, but the Lisp group was all self selected experts. Read carefully the stated problem and explain to me how anyone could take 63 hours to complete it in Java? The average experience of their Java sample set was 7.7 years!?!!!!! Didn't Java come out in 1995? Where did they find a panel of OAK seed developers? After re-reading that section it looks like he interchanges "years of programming experience" with "years of experience in that language". So why weren't we given the average number of years with experience in that particular language?

      Secondly he was using a task which Lisp is very good at, and well optimized for - list processing. People working in Lisp tend to be well exposed to this kind of problem.

      --
      Education is a better safeguard of liberty than a standing army.
      Edward Everett (1794 - 1865)
    7. Re:It's about the API by reflective+recursion · · Score: 2, Informative
      It has a massively restricted API.
      Oh my god. Please. Get CMUCL or CLISP. These are Common Lisp implementations (not Scheme). I am simply amazed at the library features available that even C does not have. And they do have a FFI (foreign function interface) which allows you to call C functions (albeit, not portably).

      Do yourself a favor and learn about Common Lisp. Not all members of the LISP family are equal. You are most likely thinking of Scheme. Scheme is a reduced API (on purpose) used mostly for academic purposes. It is most likely what you are taught in CS at the University. Common Lisp is the API heavy LISP with everything (probably the kitchen sink too! though I haven't found it yet).

      Great place to start
      The Common Lisp HyperSpec (The ANSI CL standard reference) -- view this for the API features

      Java's great strength is that it has a huge set of APIs, all in a unified form, making programming a less repetitive and painful experience. Java is for people who understand that recoding the same search tree three hundred times is not going to make them richer, cooler or a better programmer. LISP is for people with time to waste.
      You obviously do not know or understand LISP (the entire family). Learn it (CL would be your best bet). Do not just trash it without understand what it is all about.
      --
      Dijkstra Considered Dead
    8. Re:It's about the API by multicsfan · · Score: 2
      I found FORTRAN very easy to learn and use. I've found C/C++ very difficult. Actually, of all the languages I have used, C and C++ have been the two hardest to learn.

      I've worked in 10 different flavors of FORTRAN, several versions of PL/1, several versions of Basic, several assemblers including machines no one here has probably heard of (ITT ADX-9303, interrupt driven I/O only), SNOBOL, APL, LISP, PERL, and others I don't readily remember. I haven't looked at JAVA. C/C++/JAVA seem to be languages that need huge support libraries to overcome the lack of builtin features and capabilities.

      My use of C/C++ has always been frustrated by the lack of language features and abilities that make things easy.

    9. Re:It's about the API by RevAaron · · Score: 2

      Common Lisp has a huge library as well.

      --

      Working toward a usable PDA environment in the spirit of Newton OS: Dynapad
  2. Statistically meaningless by GruffDavies · · Score: 3, Insightful
    There were only 14 participants in the study. The conclusions drawn are statistically meaningless. And without some kind of measure of the level of skill of the participants in each language prior to the experiment it's not possible to do weight the answers sensibly either.

  3. Missing the point. by ried · · Score: 3, Insightful
    The secret isn't getting a language/API to run faster than what's out there today. It's a matter of widespread adoption.

    Just like BeOS was fast as hell, it didn't matter much because 5 people used it (sorry, Be people).

    If you can create a language that will execute faster within the JVM, for example (hypothetical here), then you'd have something. Speed is relatively minor thing, and unless you code for compatibility, it won't matter how fast your stuff runs (or can be developed).

  4. Writeability vs. Readability of LISP/JAVA by Aaaaaargh! · · Score: 3, Insightful

    Programming in LISP is a breeze, Java slightly less so (at least in my mind). But what about maintenance? Other people debugging your code? Have you ever had the misfortune of modifying a poorly documented LISP program? It's a good deal harder to do than for a poorly documented Java program.

    --
    Give them an inch and they'll take a foot. Much more than that, you won't have a leg to stand on.
    1. Re:Writeability vs. Readability of LISP/JAVA by jonathan_ingram · · Score: 3, Informative

      Recursion is neither evil nor unnatural. It's the natural way to define many things.

      For example, what's the natural way to define the factorial, n! ?

      0! = 1
      n! = n * (n-1)! if n > 0

      Clear and simple.

      Suppose I have to perform a function on every node of a rooted tree:

      starting with the root:

      walk through any children.
      process the current node.

      And that will translate directly into clear and easy to understand (and easy to debug) code.

      You think and use recursion every day, you just don't recognise it. That's not to say that recursion is the only thing that should be used, but when used correctly it makes code very easy to understand.

    2. Re:Writeability vs. Readability of LISP/JAVA by Pseudonym · · Score: 2

      You're an experimentalist, right? :-)

      Seriously, LISP is to functional programming what Fortran is to imperative programming, or what Simula is to object-oriented programming. Modern functional programming is pure algebra.

      Try out Haskell, Clean, or ML. You might be pleasantly surprised.

      --
      sub f{($f)=@_;print"$f(q{$f});";}f(q{sub f{($f)=@_;print"$f(q{$f});";}f});
    3. Re:Writeability vs. Readability of LISP/JAVA by SuperKendall · · Score: 2

      I have to say that I'm a huge fan of Scheme (a lot like Lisp) and did a lot with that in school, but now I'm a corperate Java programmer...

      I'm not sure I agreee with your argument though - Yes, with a good editor (defined as Emacs, I'm not sure how well Vim would take on Lisp code [I'm probably maligning it unfairly here]) Lisp code is fairly easy to follow - though the old joke of someone having hacked in to get the Lisp code for SDI and printing out the last page as proof (4000 ')' in a row) has a ring of truth to it.

      Similarily though, loading any Java code into emacs and just running "indent-region" over the whole document will give my easily readable code even over poorly formatted and undocumented stuff. I've never run into any Java code taht wasn't easy to understand after one pass with a reformatter, and I think that would be true of almost any language now.

      --
      "There is more worth loving than we have strength to love." - Brian Jay Stanley
    4. Re:Writeability vs. Readability of LISP/JAVA by e40 · · Score: 2, Insightful
      One of the main reasons LISP is unreadable to outsiders is because of their choice to stick with such bizarre syntax...

      First, you obviously haven't used lisp. Second, you have missed the entire point of the syntax of lisp. The syntax of lisp is the same as data in lisp, s-expressions. The function read can be used to read a piece of code or a data. If you don't see the utility of this, god help you.

    5. Re:Writeability vs. Readability of LISP/JAVA by hding · · Score: 2

      Actually, it turns out to be incredibly useful for reading and writing any sort of data - not just code.

    6. Re:Writeability vs. Readability of LISP/JAVA by e40 · · Score: 2, Informative

      Yep, it enables easily-written self-modifying code.

      If you can't see the futility of this in most non-AI environments, god help you.

      Huh?? I've never written a single AI program in my life. Program and data being the same are good for far more than self-modifying programs. To name some uses: program analysis, program configuration (read and eval the data), and macros. The latter is probably the single most important thing in lisp. Unlike pattern substitution in most other languages, macros in lisp are really powerful. See this for more info on macros.

    7. Re:Writeability vs. Readability of LISP/JAVA by TWR · · Score: 2
      Tail recursion (which is what most recursive calls are) is trivial to optimize out and turn into a loop behind the scenes. That's what most LISP environments do.


      -jon

      --

      Remember Amalek.

    8. Re:Writeability vs. Readability of LISP/JAVA by hding · · Score: 2

      Actually the standard doesn't require Common Lisp to be tail recursive. A decent implementation should be, however, at least at appropriate optimization settings.

    9. Re:Writeability vs. Readability of LISP/JAVA by hding · · Score: 3, Informative

      Why is it relevant how readable a program written in some language one doesn't know is? I don't think there's anything wrong with Russian because I can't gain any understanding from looking at a Russian text. I think people who know (i.e. use regularly, not studied for two weeks one semester in school) Lisp find it perfectly readable.

    10. Re:Writeability vs. Readability of LISP/JAVA by mdalgarno · · Score: 2, Informative

      It may be worth mentioning that much Lisp code is automatically generated using Lisp's macro mechanism. Lisp's simple syntax makes this possible.

      Another point is that Lisp programs tend to be much shorter than programs in languages like Java / C++ for the equivalent functionality. See the figures in the study for example.

      This makes them significantly easier to modify and maintain.

      Mark

  5. I'm a professional who uses Java by under_score · · Score: 5, Informative

    This is quite an interesting study. I use java professionally for most things that I do (I have also used C, Objective-C and a few others in the past). I have had to work with lisp a bit. Of course I took a lisp oriented AI class in school, but since then I have also had to do some porting from lisp to Java! Perhaps it was just a factor of the people who developed the lisp code, but I found it incredibly difficult to read - and my complaint wasn't with the nesting of parentheses. It wasn't strongly typed (is there such a lisp?) and the singular type of syntax (lists) make many aspects of the code difficult to unravel. That said, there are some things I really like about lisp, in particular its dynamic nature where you can build lisp functions at runtime and execute them at runtime. Sometimes I really wish I could do this easily with Java (its possible to do, just a huge pain in the butt). I think the real issue right now is that Java (and C++) are used in the "real world", whereas lisp is mostly isolated to academia. The article point this out. I've used Java for huge projects because it is no longer considered a risky language by large organizations. For whatever reason, lisp has not developed such a reputation. Does lisp have application servers? Does lisp has db connectivity? Does lisp have CORBA bindings? Does lisp have asynchronous messaging? Does lisp have naming and directory bindings? Does lisp have web page templating functionality? I'm sure all that stuff could be built, but I doubt most of it exists right now. Therefore, lisp is not acceptable for corporate use at this time.

    1. Re:I'm a professional who uses Java by Lambdaknight · · Score: 5, Informative

      > Does lisp have application servers?

      Yes

      > Does lisp has db connectivity?

      Yes

      > Does lisp have CORBA bindings?

      Yes

      > Does lisp have asynchronous messaging?

      Yes

      > Does lisp have naming and directory bindings?

      Yes

      > Does lisp have web page templating functionality?

      Yes.

      Two points more:

      1. Doubt is not knowledge. Many people THINK they know about the popularity of Lisp because they don't hear as much about it as they hear from the hype languages (which is quite logical).

      There are far more Lisp projects going on than people imagine, only people don't scream out "HEY! COOL! I'M DOING IT WITH LISP!" they go "Yepp, I'm using Lisp." the Yahoo Store engine for instance. Microsoft's Bob. Many industrial applications (not only the academia!).

      2. The syntax isn't hard to read, it's just hard for people not used to it. This is, of course, true for every language.

      Besides: Common Lisp is not strongly typed but you can strongly type a specific function by declaring what types the arguments will have. That makes Lisp a "strong typing on demand"-language in my point of view.

      --
      -- Beware the Jabberwock, my son!
    2. Re:I'm a professional who uses Java by under_score · · Score: 2

      Most or all of those things have been built in Lisp, and many are available for free or bundled with commercial Lisps. BTW, my group uses Lisp in a corporate setting. For what we do Java would be a very inferior replacement. Okay I'll grant you that I am not very familiar with the commercial lisp vendors and what they offer. But then the question remains: why is lisp not used more in a corporate setting? Probably the real reason is based on marketing and promotion. Java has a single organization which sets/guides the development of the whole platform. Sun has spend a lot of time and money promoting and branding Java. There is one standard way of binding Java to all those different enterprise modules. Is this so in lisp? Again, I don't know, but I doubt it. Is there an enterprise standard (de facto or de jure) for lisp? Is there one organization with lots of money to promote lisp into corporations? These are probably the real reasons. My other comment just reflects my own ignorance, but that ignorance is due to the lack of unified promotion and standards for lisp.

    3. Re:I'm a professional who uses Java by under_score · · Score: 2, Informative

      Ah. Well, I do appologize for my ignorance. As I mention in another comment, then perhaps unity of promotion and standards might be other issues. The question remains: why is lisp not used more in enterprise settings while Java is rapidly overtaking c++?

    4. Re:I'm a professional who uses Java by Lambdaknight · · Score: 5, Insightful

      Well, people don't know it or have prejudices against it like you. And there's noone hyping it to the end.

      The reason why it's not hyped is because Lisp HAD a hype in its history whose decline happened to the same time (and was mostly induced by) the AI winter.

      Most Lisp programmers from that time have still a bad taste in their mouths because of that hype (mind, that the hype was over was not because Lisp is a bad language but because the AI winter) so they won't start another.

      Younger Lisp programmers (like myself) are both happy and unhappy about the lack of a hype.

      Happy because that means you have a much more undisturbed basis on which you can settle your community. The community efforts and activities are easily overseeable and you always know what's going on.

      Unhappy because the community isn't very large and so activities DO happen, but more slowly than in the Java or Perl community because we have fewer people.

      As an example: that article is from 1999 and is widely known in the Lisp community... but only today it has been published on Slashdot.

      If someone writes an article about Perl, it is released immediately here.

      Keep in mind that 2 years are an eternity in computer terms.

      --
      -- Beware the Jabberwock, my son!
    5. Re:I'm a professional who uses Java by under_score · · Score: 2

      Don't get me wrong. I don't think I said anywhere that Java was a good language. In fact you are right - there are many things that suck about it. I loved Objective-C and wished for 6 years that NextStep/OpenStep/WebObjects would catch on so that I could be one of the good-old-boys from the early days. Objective-C was a great language compared to Java. Mind you, Smalltalk and Eiffel are even better, and I know it.

    6. Re:I'm a professional who uses Java by under_score · · Score: 2

      You are right: I did and probably still do have lots of prejudices about many other computer languages including lisp. My experience with lisp is deeper than my experience with say Perl, so I thought I could offer at least a small comment. As well, I did phrase most of my comment as questions - does lisp have bindings to XXXXXX? There were two or three years when Java was really struggling to find itself: applets, gui apps, etc. That time was when I was transitioning from Objective-C to Java, mostly due to market demands and job opportunities. I'm very lucky that my enterprise development background in Objective-C is the same space that Java eventually moved into. The Java community is big and hard to get into. If I was younger and with fewer responsibilities, I would definitely be involved in something more radical and more interesting... and when I was younger, I was involved in such a thing. I have a strong interest in AI, particularly the work of Douglas Hofstadter and his compatriots. I love the CopyCat stuff done by Melanie Mitchell. Since I have this interest, I wish that I could spend more time with lisp.

    7. Re:I'm a professional who uses Java by yoghurt · · Score: 2, Insightful

      lisp *is* strongly typed. every item in lisp has a type and it is easy find its type. lisp is not statically typed. the type is associated with the data item not the variable name. this is different from how static languages like C do it. but it is strong nevertheless. btw you can always explicitly declare types and turn up the compile options to increase speed.

      second, you complain about the simple syntax. this is perhaps lisp's greatest feature. lisp supports macros like no other language. it is easy to make a program which generates code if the target has a simple syntax. why do you think gcc converts C into a lisp like language for processing? programming in the simple syntax of lisp allows you the programmer to program the language to suit your problem. alas, the power of such abstraction is sometimes not appreciated.

      database access exists for lisp. corba exists for lisp. i've seen lisp to html generators. why don't you come to comp.lang.lisp and post this. between the flames you may be enlightened.

      --
      Yoghurt
    8. Re:I'm a professional who uses Java by sammy+baby · · Score: 2
      There are far more Lisp projects going on than people imagine, only people don't scream out "HEY! COOL! I'M DOING IT WITH LISP!" they go "Yepp, I'm using Lisp." the Yahoo Store engine for instance. Microsoft's Bob. Many industrial applications (not only the academia!).


      Thank god the Microsoft Bob team didn't trumpet its use of LISP. LISP has a hard enough time getting good press as it is - why throw a poisoned pill like that in?
    9. Re:I'm a professional who uses Java by aerique · · Score: 2, Informative
      The homepages of some Lisp vendors will get you most of the things in the list. Handy link with a lot of information http://ww.telent.net/cliki/

      More Lisp vendors:

      'Free' (whatever the current definition of that is nowadays) Lisps:

    10. Re:I'm a professional who uses Java by bnenning · · Score: 2
      Objective-C was a great language compared to Java.


      No need for the "was". Objective C is the primary development language for Mac OS X, which probably already has a larger installed base than NextStep/OpenStep ever did. And GNUStep is steadily coming along.

      --
      How to solve most of our problems: 1.Lots of nuclear plants. 2.Cure aging.
    11. Re:I'm a professional who uses Java by sigue · · Score: 2, Interesting

      Right on the money, honey. I work at a company that has an e-commerce web site written in Common Lisp. When we got VC funding one of the requirements was that we eventually rewrite the whole thing in Java. Not for technical reasons, but because of their fear that we wouldn't be able to find enough good Lisp programmers. Well, we hired a boatload of Java programmers. They got approximately nothing done in about a year. We four Lisp hackers kept the site from grinding to a halt while they spent our money on Java dreams. VCs pulled out, we got rid of the Java programmers (and marketing spend-thrifts), we decided to continue with the conversion to Java, we generated 50K lines of Java code from the Lisp introspection facilities, we found that we had 10x code bloat in Java, dumped java, yay, back where we started, actually improving the site now!

      One striking thing was the complete lack of interest most of the Java programmers seemed to have in learning anything about the Lisp code. I guess they thought "how is this going to help my career"?

      Lisp is perfectly suited to web applications. Since it's mostly just application logic and sending bits out the wire, Lisp's ability to change code on the fly without restarting app servers and such is a huge win, especially since a web site often requires frequent, small updates.

    12. Re:I'm a professional who uses Java by hding · · Score: 2

      When we got VC funding one of the requirements was that we eventually rewrite the whole thing in Java. Not for technical reasons, but because of their fear that we wouldn't be able to find enough good Lisp programmers. Well, we hired a boatload of Java programmers.

      Seeing stories like this (and having the relatively sheltered career, such as it is, that I've had), I've often wondered why management worries about finding (insert language) programmers rather than just finding good programmers (with the assumption that a truly good programmer will be able to relatively rapidly acquire whatever skill set is necessary). I don't dispute that one can probably find more Java programmers than Lisp programmers, but can one find significantly more truly good Java programmers than good Lisp programmers?

      To the untrained eye (like mine), it's also always mysterious why, when your team was able to build everything necessary with four programmers, a good management would want to a) take on a lot of extra people (and salary, no doubt) and b) take on the risk associated with a transition rather than c) just make sure that you four remained sufficiently well compensated that you'd want to stay on and continue meeting their needs. It'd seem to me that c) would be not only less risky, but less expensive.

  6. Important point: Functional orientation by JohnQPublic · · Score: 2, Insightful

    The second performance result is the low development time. This can be accounted for by the fact that Lisp has a much faster debug cycle than C, C++ or Java. The compilation model for most languages is based on the idea of a compilation unit, usually a file.

    More importantly, Lisp is not "file oriented". In Lisp, a function is a function is a function - you don't have the complex mess of static/public/private/whatever.

    Of course, Lisp is also write-only, like Forth and APL.

    1. Re:Important point: Functional orientation by hding · · Score: 2

      Plus, if you really want to close this back door, you can start uninterning symbols. I can't think offhand of any way someone could get their hands on something that that's been done to.

  7. 1999 by eye.likeJava() · · Score: 3, Insightful

    That was written in 1999...

    One would be able to suggest that things have changed a little since then..

    Although java does use lots of memory..

    But it is no longer as slow..

    --
    ... although I also like C#..
    1. Re:1999 by nels_tomlinson · · Score: 2

      has the development time and the code size also fallen along with the run time?

  8. Interesting, but flawed? by tkrotchko · · Score: 5, Insightful

    Its interesting to see the results of a short study, even though the author admits to the flaw in his methodolody (primarily the subjects were self-chosen). Still, I don't think that's a fatal flaw, and I think his results do have some validity.

    However, I think the author misses a more important issue: development involving a single programmer for a relatively small task isn't the point for most organizations. Maintainability and a large pool of potential developers (for example) are a significant factor in deciding what language to use. LISP is a fabulous language, but try to find 10 programmers at a reasonable price in the next 2 weeks. Good luck.

    Also, while initial development time is important, typically testing/debug cycles are the costly part of implementation, so that's what should weigh on your mind as the area that the most gains can be made. Further, large projects are collaborative efforts, so the objects and libraries available for a particular language plays a role in how quickly you can produce quality code.

    As an aside, it would've been interesting to see the same development done with experienced Visual Basic programmer. My guess is he/she would have the lowest development cycle, and yet it wouldn't be my first choice for a large scale development project (although at the risk of being flamed, its not a bad language for just banging out a quick set of tools for my own use).

    Some of thing things I believe are more important when thinking about a programming language:

    1) Amenable to use by team of programmers
    2) Viability over a period of time (5-10 years).
    3) Large developer base
    4) Cross platform - not because I think cross-platform is a good thing by itself; rather, I think its important to avoid being locked-in to a single hardware or Operating System vendor.
    5) Mature IDE, debugging tools, and compilers.
    6) Wide applicability

    Computer languages tend to develop in response to specific needs, and most programmers will probably end up learning 5-10 languages over the course of their career. It would be helpful to have a discussion of the appropriate roles for certain computer languages, since I'm not sure any computer languages is better than any other.

    --
    You were mistaken. Which is odd, since memory shouldn't be a problem for you
    1. Re:Interesting, but flawed? by nels_tomlinson · · Score: 3, Interesting
      Some of thing things I believe are more important when thinking about a programming language:


      1) Amenable to use by team of programmers
      2) Viability over a period of time (5-10 years).
      3) Large developer base
      4) Cross platform - not because I think cross-platform is a good thing by itself; rather, I think its important to avoid being locked-in to a single hardware or Operating System vendor.
      5) Mature IDE, debugging tools, and compilers.
      6) Wide applicability



      1) Is lisp less amenable to use by a team? Can't you implement one object while I implement another? I'm asking because I don't know; all my programming has been for my own research.

      2) Lisp has been around since the 1950's, in one form or another. I find that I can read lisp code from the Lisp 1.5 programmer's manual, which originated in 1965. Our kids will probably still be able to in another 30 years.

      3) How large is large enough? Is: "language of choice for 10^7 illiterate script-kiddies" a stronger recommendation than: "there are a sufficient number of competent programmers who are proficient in the language and familiar with the problem domain"? Notice that second statement is probably not true for any of the languages discussed, for most problem domains.

      4) Except for the Microsoft offerings, pretty much everything is cross platform. Think gcc and cmucl, for easy examples.

      5) I really don't know what an IDE is. I gather it is something other than emacs, since emacs supports nearly every language, some wonderfully well (try ESS for R). I really can't comment on this one at all; perhaps someone else could?
      As for mature compilers, again, I think all of the languages mentioned so far are in fair shape there. Java and c can both use the same back end in gcc, and so does gcl.

      6) Technically, all the languages mentioned are Turing-complete ... But wide applicability means being suitable, instead of merely capable. I am not familiar with java and c++, but lisp and c (and Fortran) seem to be equally capable for the bits of number crunching I do. Lisp is wonderfully more flexible, and the debug/wish-i'd-done-it-differently/change it/debug/repeat cycle seems a good deal shorter in Lisp than the other two, for me at least.

      After going over the above, it looks to me as if personal choice and the resources immediately at hand are really the only reasons to pick lisp over c over c++ over java over lisp.

    2. Re:Interesting, but flawed? by blamanj · · Score: 2, Insightful

      I don't think that's a fatal flaw

      Well, it is, assuming you're trying to make the kind of generalization that the original paper was trying to make. The original author took a randomly selected bunch of programmers who claimed to know either Java, C, or C++ and assigned them the task. In comparison, Mr. Gat's paper was based on a call to a bunch of dedicated LISPers. whose expertise one could reasonably expect to be much higher than someone who might have taken a LISP programming class N years ago.

      You really can't compare the two papers. Either you get "experts" on both sides, or you get randomly chosen programmers on both sides, but not a mix.

  9. Re:Learning Lisp? by Lambdaknight · · Score: 3, Informative

    Yes.

    Read "Structure and Interpretation of Computer Programs" by Abelson and Sussman.

    It is a fabulous book for introduction into functional thinking and shows many enlightening things about what you can do with Lisp in general and in this case Scheme.

    Your next step might be "ANSI Common Lisp" by Paul Graham, giving an introduction into the Lisp dialect with which major applications in the industry are done (REALLY done, Franz Inc. and Xanalys, both commercial Lisp implementors and vendors have increasing sales over the years) - also a very clear and easy to follow book with lots of examples and exercises and a very cool reference which I tend to use a lot while Lisp coding.

    If you prefer online information, you can find many links and pointers to Lisp on the webpage of the Association of Lisp Users (ALU, http://www.alu.org).

    (Yes, I'm paid to code in Lisp)
    (Yes, it's a lot of fun)

    --
    -- Beware the Jabberwock, my son!
  10. Ocaml instead of Lisp by Ronniec95 · · Score: 2, Informative

    For max performance and easy integration with C-APIs try this language at http://www.ocaml.org. I only heard about it from the ICFP contest but it is a very cool language IMHO.

    1. Re:Ocaml instead of Lisp by Sarunas · · Score: 2, Informative

      http://www.bagley.org/~doug/shootout/editorial.sht ml The programming language shootout gives some more reasons why ocaml is good.

  11. There is more data available for other languages.. by crealf · · Score: 5, Informative
    The article about Lisp is a follow-up of an article by Lutz Prechelt in CACM99 (a draft is available on his page along with other articles).

    However there is more data now, as, Prechelt itself widdened the study, and published in 2000 An empirical comparison of C, C++, Java, Perl, Python, Rexx, and Tcl (a detailed technical report is here).

    If you look, from the developer point of view, Python and Perl work times are similar to those of Lisp, along with program sizes.
    Of course, from the speed point of view, in the test, none of the scripting language could compete with Lisp.

    Anyway some articles by Prechelt are interesting too (as many other research papers ; found via citeseer for instance)

  12. Lisp by DGolden · · Score: 3, Insightful

    Personally, I love LISP and Scheme. Their simple syntax makes far more sense to me than other languages.

    I think it's a classic cognitive dissonance effect that causes programmers of other languages to complain - they've spent so much time learning their pet language's wierd syntax that to admit that lisp is easier is to devalue all that effort - and no-one likes to admit they've been wasting their own time, just like windows programmers who've wasted 2 years of thier life learning the intricacies of win32, or x86 asm coders who can't admit how awful x86 asm is compared to PPC or m68k asm.

    Then again, there's a theory somewhere on the net that programming language preferences are influenced by the programmer's native natural language - I was raised partly in an Irish-speaking environment, so lisp may just naturally make more sense to me, due to the different structure of irish sentences.

    --
    Choice of masters is not freedom.
    1. Re:Lisp by scrytch · · Score: 2

      I think it's a classic cognitive dissonance effect that causes programmers of other languages to complain

      This couldn't possibly be true with :MY-PET-LANGUAGE, could it? No, must be that you're the only objective one in this universe...

      --
      I've finally had it: until slashdot gets article moderation, I am not coming back.
  13. Lisp is nice but Smalltalk is better by crovira · · Score: 3, Insightful

    Lisp is okay. The syntax is trivial but over the years it has evolved some good libraries and it is reflexive.

    You can use lisp to write/generate lisp code which you can then interpret/compile and execute. The problem comes from the architecture of the VM. It was not fundamentally designed with objects and message passing in mind.

    Prolog has a similar simple syntax but its VM is designed completely differently.

    From that respect, the Smalltalk VM is closer to the paradigm.

    While all three have had time to mature and evolve over the decades of their existence, Smalltalk has the most usable and extensive libraries to date.

    Smalltalkers find Java class libraries "quaint."

    That said, Smalltalk is still flawed because it is container based and the contained don't know they are contained unless explicitely made aware of the fact.

    This is its major flaw, as a brick in a wall can make amply clear, its in a wall and its held there. The wall is the aggregate of the relationships between the bricks.

    --
    MSBPodcast.com The opinions expressed here are my own. If you don't like 'em... Think up your own stuff.
  14. I've written 2 Lisp and 4 Java books by MarkWatson · · Score: 4, Informative
    First, great topic!

    I have written 2 Lisp books for Springer-Verlag and 4 Java books, so you bet that I have an opinion on my two favorite languages.

    First, given free choice, I would use Common LISP for most of my devlopment work. Common LISP has a huge library and is a very stable language. Although I prefer Xanalys LispWorks, there are also good free Common LISP systems.

    Java is also a great language, mainly because of the awesome class libraries and the J2EE framework (I am biased here because I am just finishing up writing a J2EE book).

    Peter Norvig once made a great comment on Java and Lisp (roughly quoting him): Java is only half as good as Lisp for AI but that is good enough.

    Anyway, I find that both Java and Common LISP are very efficient environments to code in. I only use Java for my work because that is what my customers want.

    BTW, I have a new free web book on Java and AI on my web site - help yourself!

    Best regards,

    Mark

    -- www.markwatson.com -- Open Source and Content

    1. Re:I've written 2 Lisp and 4 Java books by hding · · Score: 2

      Two good choices are CMUCL and CLisp. Information for both of these may be found at www.cons.org. (Warning-there have been some problems with the site lately. Be patient or try again if there is a problem. :-) Emacs Lisp is mostly suited for writing Emacs and extensions thereof; it differs from more modern Lisps in some important ways. Of course, one should still know it to facilitate customization of Emacs. :-)

    2. Re:I've written 2 Lisp and 4 Java books by MarkWatson · · Score: 2, Informative
      Hello Rinikusu,

      The Xananlys free educational system is very usable as-is. The only real constraints on the free personal version is that it will only run for 5 hours (then you simple have to restart the IDE) and that you can not save small stand-alone executables.

      That said, try the free personal version, and if later you need to distribute small compiled applications for Linux or Windows, then buy the Pro version.

      Under Linux, CMU Common LISP is free and generates very fast compiled code. Under Windows, Linux, etc., CLisp is free and although uses compiled pseudo-code, it is fairly fast, and uses very little memory so it is very appropriate for writing small scripts and utility programs.

      -Mark

  15. IDE can be a great training tool... by SuperKendall · · Score: 2

    I myself pretty much just Emacs for all my Java programming.

    However, I have to say that an IDE can be useful for two things - The first is helping novice programmers understand the language better and develop within your application faster (here I speak primarily of code completion). The second is debugging... I know there are many debates on weither or not debuggers are really useful and I try not to rely on them much, but sometimes when you have a really nasty multithreading issue there's nothing more valuable than being able to scan system memory during runtime.

    I know many would argue against using code completeion - I myself am not sure yet weither to see it as a crutch or not (I figure it's probably better to have a solid understanding of what you're trying to call). However, cruch or no it does make it possible for lower level programmers to work more effectivley in a system and sometimes you have tasks that don't require a lot of design, just a lot of work that can be done (with supervision) by entry level people.

    So even though the presence of good IDE's may not make a language "good", I think it helps determines if a language is viable for corperate programming.

    --
    "There is more worth loving than we have strength to love." - Brian Jay Stanley
  16. Why Java succeeded, LISP can't make headway now by joneshenry · · Score: 5, Informative
    Java was never marketted as the ultimate fast language to do searching or to manipulate large data structures. What Java was marketted as was a language that was good enough for programming paradigms popular at the time such as object orientation and automatic garbage collection while providing the most comprehensive APIs under the control of one entity who would continue to push the extension of those APIs.

    In this LinuxWorld interview look what Stroustrup is hoping to someday have in the C++ standard for libraries. It's a joke, almost all of those features are already in Java. As Stroustrup says, a standard GUI framework is not "politically feasible".

    Now go listen to what Linux Torvalds is saying about what he finds to be the most exciting thing to happen to Linux the past year. Hint, it's not the completion of the kernel 2.4.x, it's KDE. The foundation of KDE's success is the triumph of Qt as the de facto standard that a large community has embraced to build an entire reimplementation of end user applications.

    To fill the void of a standard GUI framework for C++, Microsoft has dictated a set of de facto standards for Windows, and Trolltech has successfully pushed Qt as the de facto standard for Linux.

    I claim that as a whole the programming community doesn't care whether a standard is de jure or de facto, but they do care that SOME standard exists. When it comes to talking people into making the investment of time and money to learn a platform on which to base their careers, a multitude of incompatible choices is NOT the way to market.

    I find talking about LISP as one language compared to Java to be a complete joke. Whose LISP? Scheme? Whose version of Scheme, GNU's Guile? Is the Elisp in Emacs the most widely distributed implementation of LISP? Can Emacs be rewritten using Guile? What is the GUI framework for all of LISP? Anyone come up with a set of LISP APIs that are the equivalent of J2EE or Jini?

    I find it extremely disheartening that the same people who can grasp the argument that the value of networks lies in the communication people can do are incapable of applying the same reasoning to programming languages. Is it that hard to read Odlyzko and not see that people just want to do the same thing with programming languages--talk among themselves. The modern paradigm for software where the money is being made is getting things to work with each other. Dinosaur languages that wait around for decades while slow bureaucratic committees create nonsolutions are going to get stomped by faster moving mammals such as Java pushed by single-decision vendors. And so are fragmented languages with a multitude of incompatible and incomplete implementations such as LISP.

  17. Not really by SuperKendall · · Score: 2

    I spent a lot of time with scheme in school - I took a number of classes that used scheme and was also a scheme labby (where I helped students in scheme classes and also led sessions to try and help people explore concepts presented in class in more depth). Even now I personally think Scheme is the best language in the world to teach programming.

    However, I'm also a corperate Java programmer. Thus I have no congnitive dissidence at all, I'm really comfortable in both lnaguges, in fact I use a lot of techniques I learned in Scheme in Java. I have to say that for corperate programming, Java is simply a better choice at the moment.

    There are a lot of reasons why I think that, mostly boiling down to a rich set of tools, corperate system API's, and a lot of programmers with a wide range of experience. But I don't think cognitive dissonance is the problem - if Scheme became viable you'd see a lot of programmers head that way just like they've headed to Java from other languages.

    --
    "There is more worth loving than we have strength to love." - Brian Jay Stanley
  18. Re:Perhaps not quite as illuminating as it appears by Wavicle · · Score: 2
    I agree with your first and second points... And your third... aww heck, I agree with all your points.

    This sort of thing is an annoying recurring theme in our industry. The fastest G4 based Macs may or may not be faster than the fastest P4 based PCs. But it's impossible to get a good comparison because the Mac addicts keep pointing at photoshop and the PC addicts keep pointing at Quake.

    According to the two economists who determined that the Dvorak keyboard is better than the Qwerty keyboard without the burden of scientific research: Java, C and C++ *must* be better than Lisp; or Lisp does not provide significant advantages over Java, C and C++ because if Lisp did, then businesses would adopt it in order to save money.

    Just once I'd like to see a really fair comparison based on rigorous effort.

    --
    Education is a better safeguard of liberty than a standing army.
    Edward Everett (1794 - 1865)
  19. Why Lisp is just academic by scruffy · · Score: 2

    One reason Lisp has fallen because the Lisp community could not resist the temptation of feature creep. Common Lisp is a huge language with all sorts of cruft and a difficult to understand packaging system. Java, on the other hand, is a much smaller language, but with a huge API. It is much easier to learn Java and then to pick and choose what parts of the API you need to know. Lisp should have standardized and modularized the API rather than bloating the language.

  20. What about GUIs? by prizog · · Score: 2

    Where are the good, cross-platform GUI toolkits for Lisp?

    1. Re:What about GUIs? by hding · · Score: 2

      There's always CLIM for such things.

    2. Re:What about GUIs? by scrytch · · Score: 2

      Where are the good, cross-platform GUI toolkits for Lisp?

      Hm, I'm still looking for a *good* GUI toolkit for Java, preferably something with nice functional constraints instead of the overarchitected event framework of awt and swing. About the only GUI framework that I really liked was FranTk in Haskell, which sadly was a ferocious pain to compile. I'm not a functional nazi, I just don't like doing everything "by hand", which is what it feels like in Java. Last I looked there wasn't even a packing layout manager in Java like Tcl/Tk has, I had to get it third-party.

      Anyway, I plugged your question verbatim (minus the question mark at the end) into Google, and came up with a gigantic list of toolkits, including a standard API for GUIs in common lisp called CLIM.

      Any toolkit is going to be limited to the platforms it's been ported to -- it's not as if Swing magically works when the core JVM is ported after all.

      --
      I've finally had it: until slashdot gets article moderation, I am not coming back.
    3. Re:What about GUIs? by prizog · · Score: 2, Interesting

      Java's event-driven GUI system is easy to code for, but is limited by the simplistic event model. Still, it does not make much totally impossible, so in my book, it is decent.

      I am not sure what you mean by a packing layout manager (but you can tell me next time you see me on IRC).

      I do see a list of toolkits, but they all seem to be based on terrible base toolkits, like Tk or WxWindows, or are not portable at all.

      CLIM is a good idea, but I cannot find any free (beer) implementations, which seriously limits its usefulness.

      Swing has the property that, since it is written almost entirely in Java, it can be ported with little effort. Bindings need not be written for each component, but only for windows (Xlib meaning) and a few other things. Unfortunately, this tends to make it a bit slow, but that's not a concern for me.

    4. Re:What about GUIs? by hding · · Score: 2

      There is a Free-CLIM project, although I don't know its status

      It's unclear, though, how the lack of free CLIM implementations makes any statements about its usefulness. It merely indicates that you are either unable or unwilling to use a commercial implementation, which is fine, but really only makes a very local statement about it's usefulness (viz. that it's not useful to you in particular).

    5. Re:What about GUIs? by prizog · · Score: 2

      Well, it means that few people will use it, so there will be a small library of pre-made components to work from, and a small set of work to learn from. It means that employers will have to work hard to find employees who know it, rather than being able to hire from a large base of people who already know it.

  21. Read the history of LISP Was Re:Lisp by joneshenry · · Score: 2
    The final form of LISP notation occurred because of accident and the prejudices of the LISP community, exactly the factors you disparage. From McCarthy's recollections "The unexpected appearance of an interpreter tended to freeze the form of the language...Another reason for the initial acceptance of awkwardnesses in the internal form of LISP is that we still expected to switch to writing programs as M-expressions...It just receded into the indefinite future, and a new
    generation of programmers appeared who preferred internal notation to any FORTRAN-like or ALGOL-like notation that could be devised." LISP was started as an extension of Fortran. The M-notation could not be used directly because of the character limitations of the IBM 026 key punch. S. R. Russell's observation about eval led to the implementation of an actual interpreter for LISP, this is what froze the language. This resistance to change was so great that it was impossible for McCarthy to even change 'car' and 'cdr' to names that had sense.

    It is also good to read the history of LISP because we need to remember that LISP was developed specifically for the killer application of artificial intelligence. Unfortunately looking back we can now see that artificial intelligence stagnated for decades. What happened? The field was caught in an unhealthy fascination with exactitude, theorem-proving, logic. While these mathematical ideas are beautiful and engrossing, we have to keep in mind we are dealing with a problem area of artificial intelligence that is supposed to work in the real world. The right way to progress in artificial intelligence was to embrace statistical, evolutionary approaches.

    Of course LISP is Turing-complete (provably), so in theory anything can be programmed in it. But we have to understand from reading the history the mindset associated with its origins, origins that are linked to an attempt to subsume artificial intelligence as a subset of mathematical logic. In this context, LISP can be argued to be computer science's greatest catastrophe. If great programs to finally succeed in conquering artificial intelligence are only now being written in LISP, it is just evidence that, academically speaking, the previous generation needed to die off to let progress resume.

  22. The link should be... by Futurepower(tm) · · Score: 2


    The link should be Kawa.



    ____________

    Something should be done about this:

    Post Comment
    Lameness filter encountered.
    Your comment violated the postercomment compression filter. Comment aborted

    --
    Bush's education improvements were
  23. Re:Multithreaded Apps? by hding · · Score: 2

    Specifically what features do you feel that a Lisp such as Lispworks (as Mark mentioned) or Allegro do you feel are missing that makes building multi-threaded applications a problem? For your reference, the chapter of the Lispworks Reference manual describing the MP package is here

  24. LISP is first computer language at MIT by peter303 · · Score: 2

    MITs Computer Science 101 (6.001) is based a the
    LISP variant called SCHEME. About half of the
    MIT students take this course required for all
    computer science majors and electrical engineeers.
    This course has used LISP for most of its 30 year
    history except one term when it tried Java.
    It is presumed the most MIT students have programmed
    extensively in high school one of the more practical language like C or JAVA.
    This purpose of this course is to teach fundamental
    program constructs and not how to get a job.

  25. Lisp is standarized. by ArmorFiend · · Score: 2, Informative

    Moderators, if you're still here: please mod this up.

    > I find talking about LISP as one language compared
    > to Java to be a complete joke. Whose LISP? Scheme?
    > Whose version of Scheme, GNU's Guile? Is the Elisp
    > in Emacs the most widely distributed
    > implementation of LISP? Can Emacs be rewritten
    > using Guile? What is the GUI framework for all of
    > LISP? Anyone come up with a set of LISP APIs that
    > are the equivalent of J2EE or Jini?

    There are exactly two dialects of Lisp that have relevance to this discussion.

    ANSI COMMON LISP is designed for large application development by a large team of programmers. It is the first object oriented langauge to have an ANSI standard. (circa 1990).

    Scheme is a minimalist language designed for ease of learning. It is specified by R5RS.

  26. Common Lisp vs. Lisp by bugbear · · Score: 3, Insightful

    You make a good point when you ask "Whose Lisp?" Lisp is a family of languages. Common Lisp, which is arguably the leading dialect now, has major flaws. It was designed by a committee, and not especially liked even by them. Common Lisp is like a big ugly old wrestler: powerful but lumpy and ill-mannered (i.e. impolite to the OS and other applications).

    Disputes about Lisp are often about two different things. Those who attack Lisp are usually attacking Common Lisp. Those who defend Lisp are usually defending Lisp, the family.

    Lisp the family sounds like a vague concept, but there is a solid core there. You could approximate it as either Common Lisp minus the crap, or as Scheme (another family member) plus more data structures and libraries.

    Lisp would certainly look better if it had a better representative to send to the Language Beauty Contest than the lumpy old wrestler. It is about time someone made a nice new dialect. In the meantime I'll still take the wrestler over the alternatives, but the price I have to pay is using a language that is considered unfashionable.

    1. Re:Common Lisp vs. Lisp by Goldhammer · · Score: 2, Insightful

      Those who attack Lisp are usually attacking Common Lisp.

      In my experience, most people who "attack Lisp" direct their tirades against Lisp 1 - 1.5, or the all-caps Lisp which appears in, say, Tanimoto's Elements of Artificial Intelligence (1987). Analogous are those clever critics who blast Fortran. Only after you inquire deeper, it becomes clear they are talking about Fortran-77, Fortan-66, Fortran-IV, or even Fortran-II.

  27. Some hopefully useful points by dlakelan · · Score: 2, Informative

    First off, one of the best spokespersons for Lisp is Paul Graham, author of "On Lisp" and "ANSI Common Lisp". His web site is Here.

    Reading through his articles will give you a better sense of what lisp is about. One that I'd like to see people comment on is: java's cover ... It resonates with my experience as well. Also This response to his java's cover article succinctly makes a good point that covers most of the bickering found here...

    I personally think that the argument that Lisp is not widely known, and therefore not enough programmers exist to support corporate projects is bogus. The fact that you can hire someone who claims to know C++ does NOT in any way shape or form mean that you can hire someone who will solve your C++ programming problem! See my own web site for more on that.

    I personally believe that if you have a large C++ program you're working on and need to hire a new person or a replacement who already claims to know C++, the start up cost for that person is the same as if you have a Lisp program doing the same thing, and need to hire someone AND train them to use Lisp. Why? the training more than pays for itself because it gives the new person a formal introduction to your project, and Lisp is a more productive system than C++ for most tasks. Furthermore, it's quite likely that the person who claims to know C++ doesn't know it as well as you would like, and therefore the fact that you haven't formally trained them on your project is a cost you aren't considering.

    One of the points that the original article by the fellow at NASA makes is that Lisp turned out to have a very low standard deviation of run-time and development time. What this basically says is that the lisp programs were more consistent. This is a very good thing as anyone who has ever had deadlines knows.

    Yes, the JVM version used in this study is old, but lets face it that would affect the average, but wouldn't affect the standard deviation much. Java programs are more likely to be slow, as are C++ programs!

    The point about lisp being a memory hog that a few people have made here is invalid as well. The NASA article states:

    Memory consumption for Lisp was significantly higher than for C/C++ and roughly comparable to Java. However, this result is somewhat misleading for two reasons. First, Lisp and Java both do internal memory management using garbage collection, so it is often the case that the Lisp and Java runtimes will allocate memory from the operating system this is not actually being used by the application program.

    People here have interpreted this to mean that the system is a memory hog anyway. In fact many lisp systems reserve a large chunk of their address space, which makes it look like a large amount of memory is in use. However the operating system has really just reserved it, not allocated it. When you touch one of the pages it does get allocated. So it LOOKS like you're using a LOT of memory, but in fact because of the VM system, you are NOT using very much memory at all.

    The biggest reasons people don't use Lisp are they either don't understand Lisp, or have been forced by clients or supervisors to use something else.

    --
    ((lambda (x) (x x)) (lambda (x) (x x))) http://www.endpointcomputing.com a scientific approach to custom computing.
  28. REPOST:A classic /. posting on languages as fasion by Ars-Fartsica · · Score: 2

    Don't know who posted this a while back, or on what topic: but it makes sense when these args come up:

    --------------------
    You Work in a Fashion Industry

    I've spent the last several years trying to explain to colleagues why
    they should start using another obscure-but-good language, Eiffel, to no avail.
    Here is what I have learned. Note that this is not about the pros and cons of
    particular languages or paradigms, its about the way the programming language
    industry actually works.

    The language industry is dominated by network effects. There are major
    costs with using a minority language, and for an individual project these
    completely outweigh the benefits, even when the benefits are very large. Hence
    it is generally far better to stay with a majority language. The costs of a
    minority language include:

    Support. Sure, you can get a GPL compiler for most languages, but on a project
    you don't want to have your coders digging into the code trying to
    fix a bug, you want them writing code. Support is something you outsource.

    Performance. Every minority language claims to be faster than C, but often
    isn't in practice. Whatever the truth, C and C++ are at least known
    quantities. Maybe the minority language will be faster, maybe slower. If its
    faster, well gee so what. If its slower then you have a major problem.

    Tool support. These days even small projects start by drawing UML diagrams and
    then converting these automatically into class templates. CASE
    tool vendors don't support minority languages. Ditto for testing and
    documentation tools. Little things like tying your compiler to your
    configuration control manager might potentially be major headaches. Again, its
    more risk that the PM can do without.

    Nobody ever got fired for buying C/C++/Java. If you are a PM this is a major
    issue. Every language is going to bring some headaches, but if you have chosen
    a minority language then these headaches can be turned into an excuse for
    project failure, and hence for hanging you out to dry.

    Trained staff in a minority language are going to be rare. This does not
    necessarily make them more expensive (nobody else wants them), but it
    does make recruitment much harder and more uncertain. Alternatively you have to
    train all your existing people in the new language. And for Functional
    Languages its not just another syntax, its a whole new way of thinking. The
    industry went through this with OO languages, and many PMs have vivid memories
    of reams of non-OO obfuscated C++ written by a bunch of C hackers who had been
    sent on a one week C++ course. Getting your head around a new paradigm can take
    months, and this is time that the project just does not have.

    So, overall the PMs want to go with popular languages, not for PHM
    reasons, but for entirely rational local reasons. But rational local decisions
    turn into globally arbitrary decisions, as the entire herd gallops off in a
    random direction chosen only because most of the herd thought that most of the
    herd were headed that way.

    The lesson of this is that if you want to introduce a language, you don't
    concentrate on making it a good language, you try to persuade the herd of
    programmers, PMs and tool vendors that your language is the Next Big Thing. The
    important point here is not how much the language will do for productivity,
    quality and cost, it is to create the perception that everyone else thinks that
    this language will be the next big thing.

    There are two ways to do this. One way is to tackle the whole industry at once.
    For an object lesson in how to do this, see Java. For an object lesson
    in how not to do it, see Eiffel. Believe me, I know all about this. I have
    spent a long time giving presentations extolling the technical virtues of
    Eiffel, only to have my audience say "Yes, but in the Real World....". In the
    Real World what counts is the network effects. And you know what? My audiences
    were right. It has taken me a long time to realise this.

    The other more interesting and more promising way to introduce a new
    language is to identify a niche market and attack that. Once you have taken
    over your niche you can expand to nearby niches and start to build momentum.
    Python is doing exactly this in web serving, for example. Web serving is a good
    niche because lots of people do it, and productivity and quality generally
    count for more than raw performance. Projects also tend to be small, so
    experiments are not the Career Limiting Moves they are for large projects.
    Education can also be a useful niche if you can afford to take the long view,
    which is how Pascal, Basic and Unix got started.

  29. I've been coding lisp for a few years. by Convergence · · Score: 2

    And I have to say that I don't think I ever use lists... Usually, I use arrays, structures, objects and hash tables. Lisp has support for multidimensional arrays and you can define your own structures or classes.

    And, I'll say that with CMUCL, it compiles down to the same assembly as C does.

    Try a modern lisp, say, one written in the last 10 years.. Or, read `Common Lisp the Language', which dates back to the early 80's.

  30. We do by Goonie · · Score: 2
    GnuCash uses guile scheme extensively.

    Good things about using guile scheme:

    • Functional programming (map, lambda etc.) is a nice way to work, most of the time. You can often write less code to do the same thing than you would in other languages, and the workings are often clearer.
    • Scheme makes translating data into an externally writable format, and reading back in again, trivial. It's kinda like instant XML :)
    • Mixing C and scheme is easy, particularly with the nifty tool g-wrap one of the other GnuCash developer maintains :)
    • Guile is getting better with every release.

    Major downsides to scheme

    • There's a lot fewer programmers out there who know scheme than, say, Perl. This puts up a bit of a barrier to participation for some people.
    • The language is sometimes almost too flexible, allowing people to write scheme in idiosyncratic style that's a little hard to read. There's less agreement on the "right way to do things" that you might find in, say, C.

      However, it's not an insuperable barrier. Provided people use a bit of common sense and design clean interfaces (and document them) it's generally not too much of a problem.

    • Guile is constantly being improved :) Seriously, the improvements are all good and necessary, but dealing with version clashes is perhaps more of an issue than with other languages at this stage.

    In any case, I'm convinced that using guile has been a big net win for the project.The scope that scheme is used in just keeps growing, because it's just so damn convenient.

    Disclaimer: speaking for me, not my employer.

    --

    Any sufficiently advanced technology is indistinguishable from a rigged demo
    --Andy Finkel (J. Klass?)
  31. Re:it's in the name by RevAaron · · Score: 2

    Definately Lisp. Lisp conjures up visions of hippy coders, drugs, sex, and rock & roll. Late nights at Berkeley, coding in Lisp fueled by LSD. Java evokes a vision of a stereotypical nerd, with no life or social skills, who code in Java because it means a job- and that job means money, which could possibly buy him friends and or a whore, to give him some hollow sense of identify or life enjoyment. Java brings to mind the image of a IT manage sucking off the collective cock of Sun for the sake of a greasy buck.

    --

    Working toward a usable PDA environment in the spirit of Newton OS: Dynapad
  32. Functional vs. OO by sohp · · Score: 2, Insightful

    Face it, functional program languages do not represent real-world processes in ways that non-technical (particularly non-mathematical) people think, object-oriented languages do. Now any programmer worth his salt can, given sufficient resources, do the mapping of user requirements to functional constructs just fine, but for business application programming, it's just much more effective to say "the Ledger object sums all the values in the Activity column" to a business user than "the accumulate function is mapped over the list of transaction elements"

  33. Re:Having done some things in lisp by hding · · Score: 2

    Agreed that Lisp won't put you close to the hardware (in most cases - there are always the Lisp machines :-). Disagreed that it's hard to do bit twiddling. In fact, there are two different good ways to do bit twiddling: bit-arrays and their associated functions, and ordinary integers together with the logwhatever, dpb, ldb etc. functions.

    I can't really address suggestion 1, though I can't ever remember being particularly ill-treated by anyone. As for 2.:

    • Lispworks is a real development environment too (it's the one I use) which is less expensive than ACL
    • Corman Lisp is a real development environment too (though I admit to not fancying it that much) which is much less expensive than ACL or even Lispworks
    • If a truly free solution is desired, what's wrong with CLisp + (X)emacs, which I've also used under Windows?
  34. Lisp and Java are both good langauges by dlw · · Score: 3, Insightful

    In response to the discussion of the paper "Lisp as an Alternative To
    Java" by Erran Gat, 1999:

    I have a lot of experience with both Common Lisp and Java. I like
    both langauges. Although I spent many years of my life as an
    enthusiastic Lisp booster, if I were to start a new project now, under
    most circumstances that I can imagine, I would select Java. But the
    reasons don't have that much to do with deep programming language
    concepts. (More about my credentials later.)

    In the following, when I say "Lisp" I mean "contemporary Common Lisp
    including CLOS" if I don't say otherwise. I talk about Lisp as it is
    now. Lisp's history is an interesting subject but quite irrelevant to
    the questions brought up by the paper.

    >> The Erran Gat paper of 1999

    The experiment and results in this paper don't persuade me of
    anything. The programmers were self-selected; the Java programmers
    were apparently quite inexperienced; the sample size is just too
    small; judging a whole langauge based on a single programming problem
    is too narrow. A small programming exercise like this tests only a
    small fraction of the interesting aspects of programming.

    The paper is valuable in that it makes you think harder about the
    "which langauge is faster" question. Remember, langauages don't have
    speeds; langauge implementations have speeds. And what you have heard
    may not be true. Be skeptical of "common wisdom" about what's slow
    and what's fast; such "common wisdom" is often outdated, limited to
    particular contexts, or just plain wrong.

    >> Why isn't Lisp more popular?

    A language's popularity is strongly influenced by "network effects":
    that is, as more people use a language, it becomes more desirable to
    use. It is hard for a new language to "break through", and once it
    does there is a strong positive-feedback effect. Breaking through is
    very difficult and depends a lot on timing, luck, and often on
    forceful publicity and marketing.

    Java managed to do it, due to a confluence of many factors. It was in
    the right place at the right time. Java's early success had a lot to
    do with the rise of the World Wide Web, the decision of Netscape to
    incorporate Java into their browser, the politics of Microsoft's entry
    into the Internet area, the use of Sun's marketing resources, Sun's
    decision to give out the implementation for free, and many other
    factors on top of the technical merits (and demerits) of the language
    and its then-available implementation.

    Lisp's attempts to break through didn't succeed because the right
    confluence didn't happen, partly due to luck and partly due to
    ineptness of all of us who were hoping to promote it. It did not help
    that Lisp was marketed primarily on the coat-tails of the "AI
    industry" of the 1980's, which did not succeed as an industry
    (although many parts of the AI technology are alive, well, and making
    money today). It was also hurt by claims that Lisp could only run
    well on special-purpose hardware, by its unusual syntax that puts off
    so many people initially, by the lack of good free implementations (at
    the time); I could go on and on.

    It has helped Java's cause that there is one organization promoting
    and defining the langauge and establishing standard API's in so many
    areas. Many Lisp enthusiasts put their energy into refining and
    improving the language (resulting in excellent technology such as
    Scheme and Dylan) rather than all concentrating on stabilizing and
    developing one standard.

    The extensive set of standard API's created by Sun and the Java
    Community Process is very valuable. There just isn't any Lisp
    equivalent standard API for JMS, JDBC, Enterprise JavaBeans, and so on.

    The positive-feedback "network" effects is extremely valuable to
    Java's cause. It's much easier to find trained Java programmers than
    trained Lisp programmers. All kinds of tools and libraries are
    available (many free), many more than for Lisp. There are lots of
    books available about Java, so many that even the subset that are
    *good* books is pretty large, and not just the core Java language but
    facilities such as RMI, Enterprise JavaBeans, JDBC, JMS, and on and
    on.

    For example, there are many commercial producers of messaging
    subsystems that implement the JMS specification, and competition
    between them is driving higher functionality and lower prices.
    There's nothing like that going on for messaging subsystems and Lisp.
    This has nothing to do with any technical features of Java and Lisp as
    languages.

    >> Lisp as a General-Purpose Language -- Lisp is not "exotic"

    "Lisp" means different things to different people. If you read "The
    Structure and Interpretation of Programming Langauages", you're going
    to see Scheme code that is fundamentally different from the way code
    looks in most langauges. I think this is all extremely interesting
    and valuable, but it's not what I have spent my time on.

    To me, Lisp is general-purpose programming language in which I have
    done all kinds of system programming. In my experience, Lisp is a lot
    less "exotic" than some people might expect. For example, the whole
    "Lisp is functional, not procedural" business is largely irrelevant.
    The control structure and overall organization of a program in Common
    Lisp is extremely similar to that of a Java or C++ program. All these
    languages have subroutine calling, object-oriented programming,
    iteration, recursion, data structures, structured programming,
    exceptions, multithreading, etc.

    Any claims that groups can't program in Lisp, or that Lisp programs
    are inherently unmaintainable, are nonsense. There is nothing about
    writing a program in Lisp that makes it harder to maintain than a
    program in C++ or Java.

    >> Static Typing

    Static typing is one of the biggest differences. I agree that Common
    Lisp basically does not have static typing (yes, I know about
    "declare"). Some languages have static typing that is so restrictive
    that it seriously gets in the way of getting useful work done, and in
    the Old Days we of the Lisp world were very much reacting to
    constricting type systems. I am pretty happy with the Java concept of
    types, which I feel provides useful expression of intent in the code,
    and useful compile-time error checking, and doesn't get in your way
    very much. The parameterized typing coming to Java (in JDK 1.5, last
    I heard) should improve the situation further. Still in all, it's not
    that big of a deal, and if I went back to using Lisp without static
    typing I don't thihk my life would be all that different.

    >> Parentheses and Macros

    Lisp's unusual syntax, with the parentheses and what used to be called
    "Polish notation" (i.e. no infix operators), bothers some people. It
    looks unusual and unwieldy to those who are unaccustomed to it.
    However, once you get used to it, and if you use a decent programming
    environment (particularly a text editor that can "indent for Lisp" and
    otherwise knows Lisp syntax, such as but not necessarily Emacs), you
    quickly get used to it and it seems perfectly normal. (It is also
    possible to make a Lisp-family langauge with a more conventional
    syntax, as the Dylan designers decided to do.)

    Lisp's ayntax allow programmers to see programs in the form of a
    simple data structure, which is the basis upon which is built the Lisp
    "macro" facility, one of the truly different and powerful features of
    Lisp. Lisp macros make Lisp an extensible language, in profound sense
    of the word "extensible". They are a form of programming abstraction
    that, properly used, can help make complex systems more simple and
    understandable. Now that I used Java, I do miss Lisp macros. On the
    other hand, it turns out it's not such a big deal, and if I had the
    power of Lisp macros in Java it would not really change my life all
    that much.

    >> My Experience

    Lisp: I wrote the first Emacs-written-in-Lisp (known variously as
    EINE, ZWEI, and Zmacs). It was in fact the second Emacs ever,
    developed concurrently with the original Emacs (written in TECO). I
    have also written in Lisp an interactive debugger, a local area
    network control program, a compiler, and an object-oriented database
    management system. I worked with small and medium-sized groups. I
    maintained lots of code written by people other than myself. I was
    one of the five co-authors of "Common Lisp: The Language". I used
    Lisp, in an implementation that eventually evolved into Common Lisp,
    between 1976 and 1988.

    Java: I was one of the reviewers of "The Java Language Specification".
    I edited early drafts for Bill Joy and Guy Steele Jr. I co-wrote the
    Java part of the ObjectStore database management system, and a
    transactional data manager called "PSE Pro for Java", both from Object
    Design. Currently I am developing business-to-business integration
    software in Java at the same company, now known as eXcelon. I have
    been using Java since early 1996. (In between I did C++.)

    I'd like to go into the question of development environments but this
    is long enough as it is. In a nutshell, I really wish I had my good
    old Lisp Machine development environment again; what I'm using for
    Java nowadays is stone knives and bearskins.

    -- Daniel Weinreb
    dlw@exceloncorp.com

  35. Re:Statistically meaningless and incomplete by |deity| · · Score: 2

    Beyond this, all of the results are based on one programming problem. I'm quite sure that I could choose a programming problem that C would be faster for then Lisp, java, and even Fortran.

    Lisp is faster then C/C++ for many tasks, however there are many tasks that Lisp is slower or completely unsuited for.

    You can't base the decision to replace a language, on the languages ability to solve one problem. C is a very general purpose language, while lisp is much better at certain tasks and is less of a general purpose language.

    The researcher was obviously looking for the result he got.

    If the research were to be unbiased, they should choose several common computer algorithms, and have each implemented by a large number of programmers in the languages to be studied. If in the end lisp outperfomed java and C/C++ in a majority of cases that would be a good argument for doing more lisp programming.

    --
    Environmentalists are their own worst enemy. ~tricklenews.com
  36. Re:Why not FORTH by Bob+Uhl · · Score: 2
    One of the neatest Forth dialects I eve rplayed with was MOPS, a really cool little tool for the Mac. Unfortunately, it appears that development on it has stalled, which is indeed a pity--it deserved far more press than ever it got. Nicely OOP, interfaced with the OS properly &c. In every way an excellent tool.

    I wish it had a Linux port, since that's what I use exclusively these days.

  37. Re:Learning Lisp? by hding · · Score: 2

    The authors got so excited about mathematical research they forgot they were trying to teach a programming language.

    You may have missed the point. The authors of SICP aren't trying to teach a programming language. They're trying to teach how to program, and, in the opinion of many (myself included), do a very good job. Scheme is incidental to their actual task (although it does suit it well).

  38. Re:it's in the name by RevAaron · · Score: 2

    If you put it that way, it's harder. Java, just as a word leads to coffee, which leads me to think about yuppies that are agressive because they have no self-worth. Lisp makes me think of... well, a little kid with a lisp, but at least that's cute.

    --

    Working toward a usable PDA environment in the spirit of Newton OS: Dynapad
  39. Lisp: OO or functional? by sigue · · Score: 2, Informative

    One of the beauties of Common Lisp is precisely that it supports both OO and functional (in the loose sense) styles of programming well. It supports each better than Java does. Common Lisp is Object Oriented, while Java is Object Obsessed. Common Lisp's object system is basically a superset of Java's. You could limit yourself to programming in a Java style in CL, but why would you want to?

    Almost any language with functions/methods can support functional programming (in the loose sense) to some degree. Some encourage it more than others. Java discourages it by, for example, not allowing true first class functions/methods, by having many constructs such as IF that don't return values, by insisting that every single bit of code must belong to a single class, etc.

    I agree to some extent that the set of available libraries is often the most important thing when deciding on a language for a project. Many of the Java APIs are made unnecessarily complex due to limitations of the language. But there sure are a lot of them.

    It's a desert topping AND a floor wax.

  40. Re:Server Side Scripting by brlewis · · Score: 2

    BRL is a Scheme-based language for server-side web programming. It uses a JVM-based Scheme underneath called Kawa, so all the Java class libraries are available as well.

  41. Does Java have web page templating? by brlewis · · Score: 2
    Does lisp have web page templating functionality?

    Does Java? The typical Java-fan critique of JSP acknowledges that Java is a lousy language to embed in web templates. There's a plethora of templating systems out there that implement various non-java syntax to embed in web pages -- webmacro, XMLC, etc. Is there one of them that could legitimately be called the "Java" web page templating system?

    JSP taglibs are a kit to build your own non-Java language to embed in HTML.

    Why not use a well-designed language that lends itself well to embedding in HTML and other markup, the Scheme-based BRL. I'm using it very successfully at work. Compare its code for sending e-mail or dealing with a database with any other language or system. I'm biased, but the code isn't. For rapid development of database-driven web apps, it cranks.

  42. Re:Learning Lisp/Scheme for real world apps by brlewis · · Score: 2

    If you're already using JDBC, seems like BRL would be an obvious choice for the database-to-XML part. With Kawa Scheme underneath, you can continue to use whatever Java objects you're already using.