As I mentioned previously, I’ve been spending a great deal of time with Objective Caml (OCaml) recently.
Why do I like it?
* Interactive use (like Lisp, Perl, & Python) via the bytecode interpreter (ocaml).
* Compilable to assembly language for a variety of processors (including recent support for Amd64) via the optimizing compiler (ocamlopt).
* Type Inferencing provides the type safety of a language that requires a type definition for each variable (like C#, C++, Pascal, etc.) without (usually) having to declare them manually. So you get the conciseness of languages like Python or PHP without the worries of possible type errors at runtime.
* Pattern Matching is like a case statement with nitrous and supercharger bolted on. See the tutorial below for examples of the neat things you can do with it.
What don’t I like?
* OCaml is so strict about type safety & so focused on performance that there are separate operators for integers and floating point numbers. While I understand the motivation, in practice it really does get in the way when working with numbers (although usually not for other types).
* Getting the command line tools to work correctly for complicated builds (at least under Windows) can be painful.
* There are many fewer libraries available for OCaml than for Python, Perl, or .NET. (However, there is good support for OpenGL under OCaml. Check out LablGL).
Learning OCaml, for C, C , Perl and Java programmers is a great tutorial to get started with. The most pleasant way I’ve found to use OCaml interactively is under emacs with the Tuareg mode. It does very nice syntax coloring and allows the sending of expressions from the editor to the OCaml toplevel one phrase at a time, which is great for interactive development.