Live data from Hacker News

Ask HN: Which functional programming language is the popular enterprise choice?

news.ycombinator.com

41–50 of 91 posts

Re: Ask HN: Which functional programming language is the popular enterprise choice?

#41

If you consider Scala functional, I think it wins the popularity contest: used by startups and established companies (Linkedin, Twitter, Meetup, Verizon, Morgan Stanley, Autodesk, HuffPo, etc, etc...) and is not "we use it in a dark corner where nobody cares" and more like "betting the whole farm on it".

I would "bet the whole farm" on Haskell before Scala.

That's not to make a dig at Scala. It's way better than Java. It's also really complicated, and the need for JVM compatibility is a big part of that. Then you have the compile speed issues, the problematic tool chain, and the fact that average Java programmers, given Scala, will create unmaintainable nightmares.

I'd use Scala over Haskell when I wanted JVM interoperability, or if I needed to train people up quickly. For a "bet the whole farm" play, existing programmer familiarity actually matters a bit less-- "the whole farm" is rarely bet on a one-month project-- and I'd pick Haskell first.

Re: Ask HN: Which functional programming language is the popular enterprise choice?

#43

Why hasn't haskell become popular?

I think that it's self-reinforcing.

Let's have an honest conversation. Haskell is a great programming language. It might be the best. It is not going to get more than a 20% market share in the programming community. It could get 1 percent, which is about 5 times what it has now (measured in available jobs) and 25 times what it had 5 years ago. It could get 5 percent. It might even get 15 percent.

Much of our industry is based on trend-chasing. This 25-year-old language that happens to be really good, but whose strongest proponents even admit that it will never have a dominant (25+ percent) market share like Java or Javascript or PHP, is not a shoo-in for "next dominant paradigm".

Functional programming may be the next important paradigm and we're seeing the best programmers and the most important work gravitate toward it, but it's never going to be the go-to tool for the business-driven Scrum engineering that seems to dominate the mainstream of software.

Re: Ask HN: Which functional programming language is the popular enterprise choice?

#45
Scala, Clojure, and Erlang come to mind. F# is another possibility, since .NET/CLR is becoming increasingly popular in the enterprise (particularly in Windows-heavy datacenters), though I don't know of a whole lot of enterprise F# deployments off the top of my head.

Erlang's a bit of a special case; while you probably won't see many enterprises consciously using it (unless they use Jabber/XMPP via ejabberd, of course), it's rather abundant behind-the-scenes with communication infrastructure, and multiple large telecom providers and OEMs (including - obviously - Ericsson) use it for their equipment and infrastructure.

Re: Ask HN: Which functional programming language is the popular enterprise choice?

#46

Elixir might pick up some mind share, similar to ruby but still keeps its erlang roots.

I don't think it's quite there, yet. Everything's in place, and Elixir is a wonderful language, but it hasn't been quite battle tested yet.

On the other hand, Erlang is pretty ubiquitous behind-the-scenes, and I wouldn't be surprised if some enterprises do develop their internal software in it.

On the third hand, since Elixir uses Erlang's runtime, it'll be subject to less required battletesting for the same reasons that JVM-based languages (like Clojure, Groovy, Scala, and JRuby) are quickly gaining popularity in enterprise environments that already use Java.

Re: Ask HN: Which functional programming language is the popular enterprise choice?

#47

Scala is getting big in the enterprise. This list http://www.quora.com/What-startups-or-tech-companies-are-usi... gives a small overview

Scala is not a functional programming language, it is OO first and foremost. It has better support for functional programming than Java 8, Python or Smalltalk. And that in itself is great.

Re: Ask HN: Which functional programming language is the popular enterprise choice?

#48
post #33

Earlier quoted context omitted.

I like Scala, but it's still got mutable state, for loops, and lots of other imperative trappings. It's got some functional features, but I don't consider it to be a functional language (IMHO). If Scala is functional, then so are Ruby, JavaScript, and a host of other languages with higher order functions and the ability to be immutable, so long as you make the effort to not mutate anything (though anything is immutab…

I'm not sure how familiar you are with scala if you are equating them in equal 'functional power' to Ruby and Javascript. Have you read Functional Programming in Scala? The fact that the language supports immutable records out of the box, type classes, monadic comprehension all make it much more pleasant to deal with the realities of immutable data. You can write immutable java, but the language doesn't make it easy…

Sadly I'm sceptical that the JVM can support practical and efficient use of functional structures such as monads. I hope this will change.

Re: Ask HN: Which functional programming language is the popular enterprise choice?

#49

Why hasn't haskell become popular?

The language is more restrictive and sometimes it's harder to get something working. Of course the payoff is immense, you end up with much more maintainable and composable code. However I'm not convinced that many enterprises care much about these properties, as they are often more of a long term win. People also have an emotional attachment to their existing tools and paradigms.

Re: Ask HN: Which functional programming language is the popular enterprise choice?

#50
post #27

Javascript / Nodejs it's multi-paradigm: scripting, object-oriented (prototype-based), imperative, functional ( source: https://en.wikipedia.org/wiki/JavaScript ) Many languages known as functional (Scala, F#, Lisp, Scheme, OCaml) are multi-paradigm languages (check out Wikipedia!), purely functional programming language like Haskell are the exception ( https://en.wikipedia.org/wiki/Purely_functional ). And the IO pa…

No IO in Haskell is purely functional. Your Haskell program wires up a computation that is eventually run by the runtime. The wiring up, as described in Haskell, supports referential transparency and composition as only pure code can. Your confusion may arise from people using the term "pure" to differentiate from "monadic".
Post reply on HN