Sign in to follow this  
choffstein

Open my mind

Recommended Posts

choffstein    1090
After having my mind opened by SML, I decided to venture further into functional languages. Next on my stop was O'Caml, which was an easy enough step from SML. After this was Erlang, which I am enjoying a lot. I have no practical uses for it next, but I like to keep its distributed design in mind. I keep trying to read SICP, but with Scheme I am simply find myself saying 'I already knew this from SML'. My mind has definitely morphed by walking down this path -- but I don't think I have hit that functional enlightenment people talk about. I just don't think SML, Erlang, or O'Caml were enough to get me there. So my question is, would learning Haskell or Lisp get me to that point? I understand that Haskell has some fairly fundamental differences from SML -- being 'truly' functional -- but will the experience be mind opening for me -- or will it just be another syntax to learn to express similar ideas? I am looking for something truly mind opening. Will Lisp or Haskell give it to me? Should I keep plugging away with Scheme? Thanks mates

Share this post


Link to post
Share on other sites
wyrmmage    146
I've never heard of any of those languages, but you will rarely find a (graphical) game that is not programmed in one of the major languages (like C/Objective C/C++, Java, OpenGl, DirectX, etc.)
I would learn one of those...once you start making larger games in obscure languages, you will most likely notice a severe decrease in performance.
-wyrmmage

Share this post


Link to post
Share on other sites
choffstein    1090
To be quite frank, I have no interest in writing games anymore. It just so happens that this is probably the best programming forums I have been to on the web -- so I decide to stick around.

But knowing only imperative languages such as C, C++, and Java is severely limiting how you think about programming. I highly recommend you learn at least one functional language.

Also, just to prove a point: Vendetta Online used Lisp for its scripting before moving to Erlang. As well, Jane Street Capital, a major firm on Wall Street, uses O'Caml for its speed and ease of use in its trading platforms and strategies. And they need tick-by-tick precision with the markets, 24/7!

As for your 'severe decrease in performance' -- well, you couldn't be more wrong. Here, read this article. Not only is the SML code shorter, easier to read as well as easier to understand -- it is faster than the C++ code!

I would highly recommend you open your mind.

Share this post


Link to post
Share on other sites
MDI    266
I'd recommend you learn Haskell or Prolog. I'd also recommend you start learning about denotational semantics and domain theory, to really understand what is going on with these languages that you are learning.

Haskell's different to SML not just due to its pure nature, but because it's an inherently lazy language - computation is delayed for as long as possible ("call-by-name").

If you really want crazy, I suggest you look into Epigram, a weird hybrid of programming language and theorem prover.

HTH

Share this post


Link to post
Share on other sites
SamLowry    1865
I wouldn't suggest Scheme as you know several functional programming languages already; Scheme is a good introductory language because of its simplicity, and it does teach you different paradigms. I'd say take a look at chapters 2 and 3 in SICP and see if there are any passages of interest to you, but don't bother going through all the details of it.

Haskell... is certainly interesting. The laziness is especially nice, as is the way you can manipulate functions in syntax-friendly ways. Learning to use Haskell is not hard, but I've found learning to use it well (making the most use of the facilities it provides) is considerably less easy, so if you want to try out Haskell, make sure you don't just solve a few problems, but find out how others are doing it (there's a nice Sudoku-solver somewhere... ah, here).

Common Lisp is certainly a language to take a look at. CLOS is a very nice object system, the way exceptions can be used is very nice, and most importantly, macro's, which are so much fun to use.

I also consider Oz to be an eye-opening language, but since you've done Erlang already, ... it might be less interesting to you than it was to me.

Prolog, as mentioned by the poster above me, is also a very nice language, one of my favorites. If you like the way Prolog works, I'd suggest Mercury, which works like Prolog, but is AFAIK a lot more efficient.

And if you really want to go crazy, try Coq, an interactive proof assistant which you can use to generate programs which are mathematically proved to be correct. Very theoretical stuff.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this