Monday, September 6, 2010

Language fork in the road

We're coming to a fork in the road for programming languages.

On one side is the set of dynamic languages. These include Ruby, Lua, and possibly Python and C#.

The other side has the functional languages, which include Scala, Haskell, Erlang, and F#.

I'm convinced that one of the two (either dynamic or functional) will be the next big thing. I'm also pretty sure that it will be only one of the two, not both.

The new languages will not replace our current ones, but supplement them. Existing applications will continue to use existing languages. Web applications (that is, non-cloud web apps) will stay with Java, ASP.NET, Javascript, and SQL for database access. Traditional PC applications will stay in C++. Mainframe accounting and finance systems will stay in COBOL.

The new languages will be used for the new applications. The applications will expand the universe of programs, not replace existing programs. (Well, they may replace some existing applications, just as word processing on PCs replaced text processing on minicomputers.)

But the question remains: which of the two will be the dominant model?

Dynamic languages have two advantages: they are easy to use and they are popular. The dynamic languages are the scripting languages but with more power and cleaner syntax. They are used by a lot of programmers today, and more programmers are joining.

The functional languages have the advantage of scalability, which makes them well-suited for cloud applications. (Some have argued that the cloud will require functional languages because of the scaling requirements.)

Dynamic languages have the spectre of unreadable, nightmare code, especially if a less-than-talented programmer attempts to do things. Functional languages have the challenge of rigorous thinking to achieve even the simplest of results. You have to think like a mathematician, not a programmer, to use them.

Right now, I'm giving the edge to the dynamic languages. My choice is driven by the popularity of dynamic languages. Functional languages may be the better quality, but just as VHS won out over Betamax due to popularity, I think the dynamic languages will win out over functional. (With much gnashing of teeth by the advocates of functional programming.)


No comments: