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.)<p>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.<p>I've never used Cobol but what little I know suggests that it may be even less fun than Ada.<p>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.<p>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.<p>As far as the other languages go, Forth is usually used to program microcontrollers, Fortran for mathematics heavy applications, Erlang for multicore applications.
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.<p>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.
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.
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 <a href="http://factorcode.org/" rel="nofollow">http://factorcode.org/</a>
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".<p>CL molds itself to the paradigm and problem domain with no bias. It allows ultimate macro power even over other Lisp dialects.<p>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 (<a href="http://wiki.portal.chalmers.se/agda/" rel="nofollow">http://wiki.portal.chalmers.se/agda/</a>). If you have any questions, come talk to us on freenode/#agda!
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.
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...