Martin Odersky opens his current presentation on Scala (at ScalaDays in NY and reprised on the West coast) with a history lesson.
What motivated the popularity of object-oriented programming? "I'm an old guy and remember this."
He suggests that Scala occupies an historical moment in the transition from an object-oriented to a functional paradigm, or as he would prefer, a confluence of these paradigms in Scala's hybrid style.
His theme is that there's more than one way to do it in Scala, and that this is a good thing because the choices you make, in everyday programming, are informed by historical practice. For example, whether you use combinators or a while loop; whether you extend a feature by subtyping or pattern matching to handle additional cases; or something as simple as whether you express an operation with a symbol (/: with the mnemonic of a falling domino) or name (foldLeft).
(One of his jokes is that /: seemed so cool but is obscure in practice; whereas ??? to mean "unimplemented" has immediate clarity for anyone looking at the code.)
History doesn't tell you that there is one right way to address a problem, but that there are two or three or nine. Odersky says -- echoing Knuth's famous edict about premature optimization -- that you mustn't worry about getting it right the first time, that in fact one of the perks of a hybrid style is that you get to experience the pleasure of improving an expression, optimizing for performance or clarity or what have you, not once, but several times. That's what makes programming fun!
For Scala, the tension between functional and imperative or object-oriented styles is not a battle to be won but an Auseinandersetzung, which is not Odersky's word but Heidegger's for the intimate love-hate relationship between two historical forces existing in close habitation.
Daniel Spiewak on the expression problem:
http://vimeo.com/user18356272/review/66548717/3531875329
ScalaDays talks are soon to be released on parleys.com.
http://parleys.com/channel/51ae1022e4b01033a7e4b6ca/presentations