Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    primarykey
    data
    text
    <p>I personally think that Clojure's syntax is very effective, concise and even beautiful once you get the hang of it. However in my view that <em>isn't</em> the most compelling reason to select a language.</p> <p>My personal reasons for preferring Clojure as my "general purpose development language of choice" after many years of Java and C# are:</p> <ul> <li><p><strong>Macro metaprogramming</strong> - Clojure is a Lisp and inherits the Lisp family "Code is Data" motto. Because the language itself is written in a form that is itself a data structure within the language (this is called <a href="http://en.wikipedia.org/wiki/Homoiconicity" rel="noreferrer">Homoiconicity</a>), it's trivial to write code that generates code in whatever form you choose . You basically never need to worry about "Design Patterns" ever again- if there's something missing in the language that you want to use, you just extend the language with a macro and move on.....</p></li> <li><p><strong>Dynamic by default</strong> - Clojure is a dynamic language by default, which means that it automatically "does the right thing" in a flexible way for most tasks. This has the effect of making you more productive. Examples are automatic overflow to BigInteger arithmetic, being able to put any object types you like in a collection, never needing to declare parameter types etc. At the same time, you <em>can</em> specify type information to improve performance if needed (by directly using primitives or providing type hints for example) - so you can get really fast performance when required.</p></li> <li><p><strong>Emphasis on functional programming</strong> with persistent, immutable data structures and lazy evaluation - in particular all the core Clojure library is designed to support this style of development by default. Once you get the hang of it (I admit it's not easy...) FP is exceptionally powerful. While you can emulate "FP-style" code in almost any language, you only really get the full advantages when it is a pervasive feature of the language (Clojure, Haskell, ML spring most obviously to mind)</p></li> <li><p><strong>Excellent multi-core concurrency</strong>. Thanks to a very novel STM system, I believe Clojure has the best concurrency story of any language at the moment (see this <a href="http://www.infoq.com/presentations/Value-Identity-State-Rich-Hickey" rel="noreferrer">video for more elaboration by Rich Hickey himself</a>)</p></li> <li><p><strong>Open source library ecosystem</strong> - I'm a big fan of open source and Clojure is very much an "open source" friendly language. The language itself and pretty much every library is open source, and if that isn't enough for you then it's trivial to call Java libraries. Given the breadth of the whole Java/JVM open source ecosystem, this means that pretty much anything you want to do is readily available in a library (a big advantage over most new languages!)</p></li> <li><p><strong>JVM interoperability</strong> - you may or not care about this, but personally it's an important feature for me to be able to integrate with libraries and tools in the Java/JVM universe. Clojure makes this very easy - Clojure objects <em>are</em> JVM objects under the hood and calling a Java method is usually as simple as <code>(.someMethod someObject someParameter)</code></p></li> <li><p><strong>Interactive development at the REPL</strong> - typical Clojure development style is to interact with a running Clojure program at the REPL. You can redefine virtually anything on the fly without having to do a compile / build / test cycle. It's an amazingly productive way of working - I basically build a running program at the REPL and then copy the right commands into a source file to run in the future. Stupid example - I have a one-liner that is able to visualise various data structures from a running program in a chart using Incanter. I can immediately see in a visual way if something is going wrong and this alone has saved me weeks of debugging....</p></li> <li><p><strong>Community</strong> - I personally like the Clojure community, which is small but fast-growing. It's got the right mix of pragmatism (i.e. getting things done), helpfulness and caring about doing things well which I think is important.</p></li> </ul>
    singulars
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. VO
      singulars
      1. This table or related slice is empty.
    2. VO
      singulars
      1. This table or related slice is empty.
    3. VO
      singulars
      1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload