Ask HN: What "exotic" language to learn?
I'm interested in learning a more exotic language for fun, and I'd like to hear some suggestions. Some I'm considering so far: Pascal, Lisp, Cobol, Fortran, Prolog, Forth, Ada, Erlang. Any others I should look at? Please no BF, lolcode and similar. Pascal is not exotic. It's one of the foundation languages that's been around for decades. If you want to learn top-down, structured programming, Pascal is easy to learn and a perfect language for small, quick one-person projects. (It's one of the first languages I learned, and the one I remember most fondly.) Having worked professionally with Ada for decades, I can tell you quite unequivocally that it's not fun; not in the least. The only reason to learn Ada is if you want to work on huge projects with hundreds of other programmers for defense contractors. I've never used Cobol but what little I know suggests that it may be even less fun than Ada. If you want to bend your mind into new shapes, Prolog would be useful. You can do things with Prolog that are much more difficult than with other languages. Prolog lets you program using the backtracking paradigm, which is useful in solving some artificial intelligence problems. If you want to learn functional programming, Lisp is often recommended, although I would probably suggest that the Racket dialect of Scheme is a better choice. As far as the other languages go, Forth is usually used to program microcontrollers, Fortran for mathematics heavy applications, Erlang for multicore applications. I like Pascal and still use it. You're basically writing your program in English, so you're not using many symbols or making any syntax errors. The only one on your list worth learning is Erlang. However, there is a JVM language called Clojure that is a form of LISP and is very worthwhile, but the main reason for learning Clojure is not that it is a form of LISP, but that, like Erlang, it deals with the issue of how to build highly scalable concurrent applications. A less exotic path to the same thing would be to use Groovy along with the Apache Camel library. Or to use Scala along with Akka which essentially is an implementation of Erlang's actorsystems in Scala. J is an interesting suggestion, but I think that it is best learned along with another more conventional functional language such as Scala or Erlang. J was really innovative back in the 1960s when it was called APL, but now it is a bit of a niche language although still highly useful for financial applications. Honestly, if you haven't worked in assembly, learning it is actually really interesting. Assembly gets my vote too. Its one of the lowest level languages you can learn and it gives you a more 'wholesome' appreciation of computing. Don't expect the ability to create something useful in it though. Clojure or Haskell would be my choices, depending on how into static typing you are or how interested in lisp you are. I really would want to learn both, and if that's an eventual goal, I think Clojure might be an easier first step. I second this. I'm pretty proficient in all of the typical languages in web development...PHP, Python, Ruby. I started SICP, but followed along in Clojure, and I've been having a blast, plus my eyes are opening to a lot of things that I needed someone smart to tell me. I don't have plans to ship Clojure in production, but it has still shaped what I'm doing on a daily basis in other languages. Here's a real exotic language for you: F18 assembly. Different from x86 assembly, it is a RISC assembly language of 32 instructions, and is runs on a stack. F18s are tiny computers, so you're not only working at the bare metal, you're working with not a lot of bare metal: they have 64 byte-words of RAM, but because the instruction set is so terse, you can usually fit 6-9 functions in there (I've fit close to 30). If you can learn to use it, the next step would be to learn to use many of them together, in parallel. A $20 dollar chip contains 144 of these cores, and they're tightly networked. Factor is, what I would call, a modernised Forth. It is actually a very practical language with batteries included. See http://factorcode.org/ I would learn Common Lisp. It's not strongly tied to a paradigm like Haskell. For the same reason I'd stay away from Clojure. I think forcing a particular view or paradigm makes a language less "exotic". CL molds itself to the paradigm and problem domain with no bias. It allows ultimate macro power even over other Lisp dialects. There are efficient compilers. It's not tied to the JVM so you can deploy native, but there is a JVM alternative if you want it. Goodness, most of those languages (with the exception of Forth and possibly Lisp) are really only interesting for historical reasons. If you're interested in seeing where the wind is blowing, you should have a look at Agda (http://wiki.portal.chalmers.se/agda/). If you have any questions, come talk to us on freenode/#agda! I really think Haskell. Purity is super cool. As is functional programming in general. If only Haskell were pure... Since I'm being downvoted, let me clarify for the “hackers”. By “pure”, I mean lacking unaccounted side effects (including crashing and non-termination). I take a rather strong view, as you can tell, of what it means to “support” pure functional programming. That is, I think it is insufficient to show that your code lacks appeals to falsehood and rampant non-termination. Because your code is linked with other code from other sources, it must be shown that appeals to falsehood and rampant non-termination are in fact _impossible_. (By “rampant non-termination” and “appeals to falsehood”, I mean the use of circular reasoning. This is distinct from structural recursion and coinduction, which can be used to do REPLs and servers.) So yes, Virginia, there is indeed a Pure Functional Programming. But you can't do it in Haskell. > So yes, Virginia, there is indeed a Pure Functional Programming. But you can't do it in Haskell. True, but if you want to get as close to purity as possible whilst actually writing usable software Haskell is the answer. I'd love it if Agda was actually a fully fledged programming language, but currently it is not. Yeah, though Idris I think will soon become the “reasonable trade-off” language that Haskell is today. We could do worse, I suppose! What I really want is a proper Epigram with OTT (or, be still my quaking heart, HoTT). > Yeah, though Idris I think will soon become the “reasonable trade-off” language That would be cool. Don't know anything about Epigram though. Dependent types is still firmly on my todo list. Come hang out with us on freenode (#agda, #coq, #idris) and we'll try to answer any questions you have about dependent types and such! You're missing a Ken Iverson language from your list. Might I suggest J? It's unlike anything you've ever seen before, unless you've worked with APL, and it'll give you a whole new perspective on programming. J is kind of mind blowing because it has some programming paradigms that are pretty strange and interesting. COBOL might have its uses later in code conversion, I hear there's a skill to reading and writing good COBOL. LISP seems to be a popular language still... I had much fun playing with Rebol OCaml MIX