6 ms·
Programming languages worth checking out
- tptacek 18y ago"Unlike other Lisps (and Schemes) you may have encountered before, Clojure comes with some interesting additions: [...] Many pre-built data structures, like Vectors, Maps, Sets, Collections, …" Here I stopped reading.
- marcocampos 18y agoWhy? It's a nice adition to the language and makes using it a much better experience. My first big project in LISP was making a Sudoku solver for a school project. Could only use basic instructions and lambdas. It was not pleasant trip :P
- smanek 18y agoBut common lisp does come with vectors (make-array), hashtables (make-hash-table), and set-operators (intersection, union, pushnew, etc) that work on lists. Also, Common Lisp (CLOS, in particular) supports multimethods (defmethod), contrary to what the author claims. And all of the special forms I saw in clojure have a counterpart in common lisp. In fact, a lot of common lisp implementations (I like SBCL) have support for threading/asynchronous action built in. The one problem is that none of that is part of the ansi spec, so most multithreaded code won't be portable between implementations. It isn't the language's fault that your teacher wouldn't let you use all these features.
- gruseom 18y agoWhat's distinctive about Clojure is not that it has them, but rather that it makes them first-class citizens in the way that lists are - i.e. provides a universal set of operators for manipulating them (or so I hear anyway). This is certainly a weakness of CL. I think this is the original point underlying the author's garbled statement, and it's an improvement specifically to CL that has nothing to do with the presence of arrays and hashtables in the language. Edit: I realize this is probably obvious, but let's not confuse what this guy says about Clojure with what Hickey has to say. He's well aware of CL and doesn't make silly claims about it.
- smanek 18y agoThat's very true. I personally like clojure - and it does provide a lot of potential advantages to common lisp. I just don't think the author of this article understands them - he's just spewing bs. Hickey does make a lot of valid points about the advantages/differences of clojure (http://clojure.org/lisps http://clojure.org/lisps) though.
- deleted 18y ago[deleted]
- kragen 18y agoAll practical Lisps (including Schemes) already have those data structures. In fact, many of them are required even by R5RS.
- schtog 18y agoThe things I like about Clojure: 1. It has the simplicity fo Scheme. 2. It has literals for datastructures. Hashmap: {"BANK" 122323 "TRANSFER" 212001} . That's it, I created one. Oh, here's a vector for you: [1 2 3 4 5]. Veru convenient, not revolutionary by any measure, just very convenient. And it doesn't sacrifice any power for that practicability. 3. It is more functional than common lisp. 4. Access to all the Java libraries. Whatever you want to do, there is a library. And yes the excessive amount of documentation you have to read to just do something simple might frustrate you but it's a lot more effective than re-solving a problem that has been solved a hundred times before. I think these things together make it an excellent language.
- Jasber 18y agoI'm curious if anyone has any experience with Io (http://iolanguage.com/ http://iolanguage.com/). The description sounds like an appealing combination: Its unusual, minimalist and yet elegant and powerful syntax reminds of Smalltalk, but the language goes far beyond that. Io is an object-oriented, prototype-based, message-based and fully-reflective programming language. This means that you use messages like in Smalltalk, you create objects like in Javascript and every bit of your code can be inspected and passed around as you see fit.
- gruseom 18y agoI played with Io a long time (like 4 or 5 years) ago, at which time it didn't seem ready for anything serious. I would expect it's gotten much better since then. It would be interesting to know what sort of apps are easy to build in it. This author doesn't seem to know his subject very well, though. To say that an object-oriented, message-based, fully-reflective programming language goes "far beyond" Smalltalk suggests ignorance of how far Smalltalk goes.
- h3rald 18y agoAs I hinted in the article, you're right: I didn't really experiment much with Smalltalk. Does Smalltalk allow the same level of reflection? Does it offer the same "freedom" as Io? I'm asking because I _presume_ it does not, but I honestly don't know.
- gruseom 18y agoSmalltalk blocks are objects that respond to messages about themselves, so yes, Smalltalk offers the same kind of reflection, in fact it invented it. (It's possible that Io takes it further in some respect, but I'd need to see details.) So which (if any) of all these languages will you use to do a real project?
- h3rald 18y agoThe very reason I wrote this article in the first place was that I couldn't make upmy mind. I am, as a matter of fact, interested in all of them: I was hoping you people could help me decide. As a matter of fact, I work as a technical writer, so I'm not going to use any of these for any big project. However, I do code in my spare time and prepare small programs to automate tasks at work, when my boss lets me. At the moment (literally) I'd like to try learning Haskell again, but it feels very difficult.
- trevelyan 18y agoexperimenting with lua this evening. be curious to hear if others have had good/bad experiences with it.
- antiform 18y agoPlaying with Lua is a blast. I don't have much experience in using it for anything but a third-order language (e.g. writing programs that write programs), but it's very lightweight, fast, and easy to pick up. I view it as a language that I use when I need the power of a programming language (as opposed to a one-off program), but not enough to justify using Perl/Python/Ruby. There are some parts that I did find annoying, however, like the fact that in the standard libraries array indexing starts at 1 instead of 0 and that it gets a bit kludgy when you try and add lots of things that are not part of standard language features, but nothing you can't overcome.
- jd 18y agoIt's great as an embedded language. The implementation is so tiny you can effortlessly change the language to change whatever it is you don't like about it. The C++ bindings aren't so great, last time I checked. The documentation is not of a consistently high quality, but it doesn't matter much because, once again, the language isn't very complex. I prefer lua to any other embeddable language, including Python.
- deleted 18y ago[deleted]
- silentbicycle 18y agoIt's one of my favorite languages, and is rapidly crowding out Python. It's a tremendously clean and powerful language. Since Lua was designed for embedding, its design favored adding a few meta-features that could be used to build task-appropriate features into the language, rather than adding to the language core. It's also a relatively quick language to learn, and is extraordinarily portable - the whole language is written in pure ANSI C. It also has tail-call optimization, closures, coroutines, and other aspects that are interesting from a pure CS standpoint, such as the way the table datatype is implemented and its register-based VM. For a good taste of Lua, skim "The Implementation of Lua 5.0" (http://www.tecgraf.puc-rio.br/~lhf/ftp/doc/jucs05.pdf http://www.tecgraf.puc-rio.br/~lhf/ftp/doc/jucs05.pdf), the quick intro to Lua in the LPEG paper (http://www.inf.puc-rio.br/~roberto/lpeg/lpeg.html http://www.inf.puc-rio.br/~roberto/lpeg/lpeg.html , around page 6 of the PDF), or _Programming in Lua_ (http://www.inf.puc-rio.br/~roberto/pil2/ http://www.inf.puc-rio.br/~roberto/pil2/). The first edition of the latter is online, though the second edition has a bunch of added material, and IMHO is well-worth buying if you get into Lua. Also, check out LuaJIT (http://luajit.org/ http://luajit.org/), if you're using i386 hardware -- it's a FAST JIT.
- joe_the_user 18y agoHmm, Nice to have all the up-and-coming languages lined-up in an internal comparison. I like Lua, Haskell and Io. I think that future languages will have to have a cleaner rather than an uglier look and syntax. For that reason, I have a visceral reaction to scala and factor. Even the one-line examples I've seen of these language have look like gibberish. I'm sure they are great in many ways but don't want them to succeed since they will make my brain hurt more. Also, I think that they won't succeed for similar reasons.
- stcredzero 18y agoDon't forget Eiffel and its progeny. Design By Contract and heavy use of assertions feels to me like it's closely related to Test First development. You also get fast runtime code out of it (as in C++ fast) in a very Pure-OO environment. (By many accounts, even more so than Java and C++.)
- jballanc 18y agoI played with Eiffel for a time, but found that Design By Contract was a bit overly restrictive for amateur programming. Now that I'm doing more professional stuff, I think it's worth looking at again. There's also a lot of Eiffel influence in Ruby, so moving over from Ruby is not so hard.
- stcredzero 18y agoWhat I've found is that you actually want restrictive when you're doing maintenance. You want to know as much as possible about the code you're changing. You want to know exactly what's in that instance variable. When you're doing prototyping, you want to delay that decision as long as you can, so you are making the most informed decision possible. And nothing informs your decisions like the act of developing and getting feedback from users. Optional static typing gives you the best of both worlds. But I don't know how you'd get the equivalent with Design By Contract/Unit Testing. Both of those feel a little unnatural to me. I'd rather just tinker, and not have to set up extra stuff before or after I code.
- agentcoops 18y agoI find Self to be worth checking out, as well (http://research.sun.com/self/ http://research.sun.com/self/) if for no other reason than seeing how fast dynamic languages can be. The research that went into it--techniques for blazing fast implementations of highly dynamic, object-oriented languages--has become especially relevant and provides the basis for many of the numerous new Javascript vms (especially V8). With regards to Smalltalk and its incredible reflective abilities, this video from OOPSLA'08 ("Smalltalk Superpowers") is particularly amusing: http://www.veoh.com/videos/v163138695pJEMGmk http://www.veoh.com/videos/v163138695pJEMGmk. Unger even does a pretty neat demo of Self.
- stcredzero 18y agoStrongtalk is definitely worth a look. The ability to have static typing when you want it is awesome! I could imagine a deployment process where code can't be deployed unless it's all statically typed. This lets you do very fluid rapid prototyping, but then firm up parts of the system once they go into production.
- gaius 18y agoSelf seems to be a dead project?
- agentcoops 18y agoActually, checking out the cvs repository on sourceforge (http://self.sourceforge.net/ http://self.sourceforge.net/), there seem to have been some recent commits; though, in general, I think you're right that there isn't much active development. There's also work on a linux port at http://www.gliebe.de/self/download.html http://www.gliebe.de/self/download.html, but I think it might be relatively defunct as well.
- felixmar 18y ago11. F# F# is a mixture of C#, OCaml and Haskell. F# will be included in the next version of Visual Studio so it's no longer just a research language. Performance is similar to C# but coding in it is faster in my experience and above all a lot nicer if you like functional programming. Because it runs on the .NET VM or Mono VM it has good multicore support unlike OCaml. Haskell is more powerful as a language, but also has it's weak aspects. The main thing F# is missing imo in comparison to Haskell is type classes. And of course the Haskell community.
- davidw 18y agoSounds interesting. How much is the community tied to Microsoft? "Runs on Mono" is ok, but if no one actually does, that's perhaps problematic for those who don't do MS.
- felixmar 18y agoGood cross-platform support is indeed very important for a programming language. The F# community is still small so there probably aren't many users on Linux and OS X. Don Syme (the creator of F#) has said that Microsoft will release the F# compiler under an open source license. I think that the future of the language will depend on it. If the F# compiler cannot be included in Linux distributions then the uptake from Linux and OS X users will be low. That would seriously hinder the (open source) community aspect of the language. I don't think that a young advanced language can survive without it.
- gaius 18y agoYou can on OSX right now do: $ sudo port install fsharp And get it, but the power of F# comes in part from its integration with .NET; OCaml has been around on OSX for years.
- gaius 18y agoIf Microsoft can work out a sane licensing arrangement for compute farms/clusters/clouds (whatever we're calling them this week) of Win 2008 Server, then F# is a game-changer of a similar scale to Google's MapReduce. That's a big if tho'. Having said that, Windows is cheaper than RHEL already...
- caustic 18y agoWhat about Prolog? Why it's not in the list?
- Tichy 18y agoIs it still being used at all? I would be interested in it, too (and I don't think Erlang is very similar to it at all???).
- kragen 18y agoErlang gets a lot of its syntax and implementation technology from Prolog, but it's true that the distinctive things about Erlang (massive shared-nothing concurrency, supervision trees, tuples, pattern-matching on binaries) have nothing in common with the distinctive things about Prolog (backtracking). They both have pattern-matching, but so do lots of other languages (even Python to a small extent). I'm pretty sure Prolog is still being used, but it doesn't have the buzz of, say, Fortran or COBOL or Pascal.
- tlrobinson 18y agoWasn't Erlang originally implemented in Prolog?
- kragen 18y agoYes.
- h3rald 18y ago...Erlang is bad enough :P
- joe_the_user 18y agoIn the quick looks I've made at each language, I found Prolog much easier to understand than Erlang. Prolog's pure logic syntax is simple if you already know 1st order expressions. Erlang borrows some syntax from Prolog but doesn't have Prolog's simplicity.
- deleted 18y ago[deleted]
- russell 18y agoIs anyone using D? Is it a lot better than C++ or just a little?
- signa11 18y agowell, i played around with it for sometime. it is pretty good e.g i really like the new (and much improved!) template mechanism especially meta-programming abilities, variadic template arguments, contracts for enforcing class/function invariants, function-literals, dynamic closures etc. the issue that i have (imho ofcourse) is that of 2 incompatible standard libraries phobos and tango, which makes it quite painful to work at anything significant/non-trivial. iirc, there was an effort to have an stl kind of thing for D, not sure how far (or in what state) it is. also, it seems to me (i can be wrong about it) that D is being marketed towards corpo-drones doing win32 (c++) stuff, rather than to linux C devs. most likely, they (corpo-drones) are moving towads C#/.net and i doubt that they are interested...
- old-gregg 18y agoThere is also an issue with an implementation: the official implementation from Walter is awkwardly packaged and lacks the source (you can't build it yourself). This pretty much turns it into a toy for Linux/OSX programmers: you can't distribute your D code, nobody will figure out how to build it. And GCC-based implementation is lagging behind in features, and also scores consistently 10-30% slower than C/C++ in benchmarks, which kills D's appeal as a performant replacement for C. What Walter needs to do, IMO, is to abandon his own implementation completely and closely work with GCC/Linux community to include high-quality D into standard GCC package. Then we may start seeing decent software written in it.
- brent 18y agoTry minikanren for all your logic programming needs: http://kanren.sourceforge.net/ http://kanren.sourceforge.net/ . :)
- mattmaroon 18y agoNoticeably missing from this is Maroon, the Ultra High Level Programming Language http://mattmaroon.com/?p=337 http://mattmaroon.com/?p=337 I guess I should have paid that guy on elance his $1,000 to code it up in C for me.