Disadvantages of purely functional programming
Good points, although I agree that a lot of them boil down to similar statements.<p>I have settled on a style of doing &quot;functional-like&quot; programming in Python and C++.  It&#x27;s more about the high level architecture than low level coding details.<p>It means being very paranoid and rigorous about state -- but still having great tools to express it!  For example: Using ZERO mutable globals, and passing state in as a parameter to functions.  Using immutable&#x2F;persistent data structures.  These techniques are done very naturally and effectively in Python and C++.  You just have to be disciplined.<p>To me there&#x27;s no real advantage to expressing something like &quot;split a string by a delimiter&quot; in a purely functional style.  Either way, you have a trivial referentially transparent function you can reuse without causing complexity in your program.  You might as well do the obvious imperative thing.<p>However there IS a benefit to threading state explicitly throughout the application, and encapsulating it in OBJECTS (yes objects).<p>For me, the thing that sealed the deal against functional languages for &quot;real work&quot; was trying to write a production quality sh parser.<p>I went down a long path of trying to do this first in OCaml and then in Lisp.  The VERY first thing that hits you over the head -- lexing -- is heavily and inherently stateful.  ocamllex and ocamlyacc to me are evidence of this paucity and poverty of purely functional solutions.  They&#x27;re just transliterating solutions from C.  Well I might as well use C then.<p>Actually, I decided to use C++, which was like my 5th choice as language.  Aside from headers and compile times, it&#x27;s a good choice.  I use &quot;functions and data&quot; (a la Rich Hickey).<p>Except my functions and data are both CLASSES.  Data objects are basically structs, except they can do things like print themselves and answer simple queries based on their values, which helps readability (e.g. 1 liners, like word.AsFuncName() ).<p>Function objects are simply classes with configuration passed to constructors.  That usually have a single method, but multiple methods are also often useful.  Calling this method is basically equivalent to calling a curried function.  But this is supremely useful for both compilers and servers, because often you have config&#x2F;params that is constant once you reach main(), and then you have params that vary per request or per file processed.  Many functions depend on both, and it&#x27;s cleaner to separate the two kinds of params.<p>So both &quot;functions and data&quot; are effectively and usefully implemented as classes.  The key is to make some classes like functions, and some classes like data.  And have more of a bipartite dependency graph, where functions depend on data, and data depends on functions.<p>When all your classes are an equal mix of data and behavior, that&#x27;s when they start getting &quot;hard-coded&quot; weird-shaped dependencies, and your program turns into fragile spaghetti.  Functions and data are a useful architectural technique, and to me it doesn&#x27;t have that much to do with Clojure or Lisp, although Hickey is certainly a great advocate.