5 ms·
I would not want to teach novice programmers a purely functional language... And that's what it comes down to, almost always. How hard is it to hire other peop
by bayesian_horse 8y ago
I would not want to teach novice programmers a purely functional language...
And that's what it comes down to, almost always. How hard is it to hire other people to work on your code, and how hard is it to bring people up to speed, who need to code, but aren't programmers. Scientists, mostly. Business people increasingly.
- wtetzner 8y agoI don't think you have to go for purely functional. Jane Street, for example, went with OCaml in part because the business people found the code easier to review than other languages.
- bayesian_horse 8y agoI've heard good things about OCaml, but it's extremely niche.
- wtetzner 8y agoSure, but that was just an example to illustrate my point. Some of these languages are viewed as hard to learn simply because they are unfamiliar. But to someone who's never programmed before, all languages are unfamiliar, and it turned out, at least in Jane Street's case, that OCaml was easier for the business people to understand than Java or C#, or even Excel macros.
- icxa 8y agoI am in no way a OCaml fan, and I primarily use Go at work. That said, the fact that OCaml is used by Bloomberg and Facebook (on multiple apps and products) alone make it not niche http://www.ocaml.org/learn/companies.html http://www.ocaml.org/learn/companies.html That plus ReasonML's growing popularity, which is essentially just a syntax extension of OCaml, makes it even further not niche.
- bayesian_horse 8y agoOh I don't doubt, that SOMEONE is using these nice languages. Still, the community of OCaml or Haskell is not nearly as big and diverse as the Python community. And that counts in all sorts of ways. You'll have much more trouble finding answers to any questions you have. You'll have less chances for community meetings or educational content. You'll definitely have more trouble finding new developers for your projects, both in business and in open source.
- icxa 8y agoAgain I am not trying to be a contrarian, but in my experience quantity != quality. You can take this statement the other way and say too much information is bad. There is a reason there are so few Go Stack Overflow questions and answers: most of Go's documentation is excellent and easy to follow and learn and they have excellent community resources, videos and guides. From what I have seen so far, the OCaml and Reason docs are great, and their communities are extremely supportive.
- jayd16 8y agoIf you throw purity out, then its no longer a language feature. You can write functional methods in any language.
- wtetzner 8y agoThere's a huge difference between "you can write functional methods in any language" and "writing functional code is default/idiomatic". Erlang doesn't support mutation at all, for example, and uses immutable types for everything. But it does let you send messages to other processes, which is a side-effect, so Erlang is not purely functional. But that doesn't mean that JavaScript is somehow just as functional as Erlang. Because it's not.
- lame88 8y agoI believe they have also cited an advantage of using OCaml being the quality of applicants they were able to pool for hiring by virtue of mainly using a functional language and being able to draw from the enthusiastic and skilled community around it. It's weird, right? In some ways, this actually has nothing to do with OCaml itself or its merits, or even the functional paradigm. I hadn't heard your example before but that's also quite interesting. I wonder how much weight these kind of side-effects account for their success, and how much is actually due to the merits of the technology itself?
- sacado2 8y agoElm could be a reasonably good first language, IMO.
- sridca 8y agoElm was what lead me to begin using Haskell for serious projects. Elm is the perfect gateway drug to Haskell.
- the_duke 8y agoI disagree. Starting with Haskell is a bad idea, no doubt. But there are easy to use functional languages that are very beginner friendly, like Elixir or Elm.
- dagw 8y agoStarting with Haskell is a bad idea, no doubt. I not sure I agree. The university I went to used Haskell for its introduction to programming courses and I think it worked pretty well for most people, and especially for people who had never programmed before. The people that did struggled the most where actually those who already knew a bit of programming, but weren't very strong programmers. The flip side is that all the students who had now had been introduced to programming via Haskell where completely confused when trying to understand OO and Java in the next course.
- bayesian_horse 8y agoI'm not talking about teaching programming to people who show up voluntarily in a computer science introductory programming course, but those who have a full-time job doing/studying something else and have to learn how to code, on the side.
- bayesian_horse 8y agoConsidering Elixir and Elm are more niche than Python, and Python is being used more widely, Python will beat both of them in terms of a first language for people not studying computer science...
- jimbokun 8y ago"I would not want to teach novice programmers a purely functional language..." It's easier than teaching them imperative programming, because it's much easier to reason about. The real problem is teaching functional programming to programmers whose brains have been damaged by years of writing imperative programs.