functional-programminglanguage-agnostic

When to use a functional programming language?


In which situations should I choose to use a functional programming language over a more verbose object-oriented language like C++, C# or Java?

I understand what functional programming is, what I don't really understand is for what types of problems is it a perfect solution?


Solution

  • Functional languages are, in my opinion, good for mainly two things: Game AIs and mathematical computations. It's good in game AIs because of its nice list manipulations (at least in Lisp and Scheme), and for mathematical computations because of its syntax. Scheme, Lisp, and Haskell have a syntax that makes mathematical computations easy to read. The last thing I have to add is that functional languages are really fun languages. My Scheme course was one of the courses I had the most fun with.