DEV Community

Rob Sinkko
Rob Sinkko

Posted on

Learning Functional Programming

I would just like some language options on where to start my learning of Functional Programming.
I've been developing since the Commodore 64 days with a focus on C, C++, Java, and C#.
Thanks!

Latest comments (39)

Collapse
 
richjdsmith profile image
Rich Smith

Take a peek at Elixir, it's a fantastic language with a great community behind it willing to answer any and all questions!

Collapse
 
courier10pt profile image
Bob van Hoove

I was going to suggest a Haskell MOOC, so I'll start by saying think Haskell is suitable for learning the core concepts :)

I would recommend Introduction to functional programming. The course is loosely based around Graham Hutton's book Programming in Haskell.

Once you've learned the core concepts it should be easy to switch to another language that may be applicable in your field of development.

Collapse
 
skillslide profile image
SkillSlide

I would definitely recommend Elixir, as it is getting very popular. It's probably already the most popular functional language.

Collapse
 
miuler profile image
Hector Miuler Malpica Gallegos
  1. Haskell
  2. Scala
  3. Rust
Collapse
 
kayis profile image
K • Edited

I think FP is a broad field and like OOP every language has its own idea how to do it right.

Haskell and PureScript for example feel to theoretical to me, with co-monads, lenses, pro-functors and what not...

OCaml on the other hand feels more approachable, but I don't really know why. All I can say that I don't feel bombarded with theoretical concepts when reading about it...

Collapse
 
jvanbruegge profile image
Jan van Brügge

I dived heads first (no prior FP experience) into Haskell and I love it. "Learn you a Haskell" and "Real world Haskell" are great online resources to get you started.
The point I like the most about Haskell, is that it has a small core. It is not some syntax sugar abomination like C++ and more recently Javascript.
Every new extension added is still desugared to this small core. Plus, type classes are just amazing.

Collapse
 
augustodossantosti profile image
Augusto Santos

I recommend Elixir for you. I started to learny it a few weeks ago and it's been a lot of fun.

The best book about this: amazon.com/Programming-Elixir-1-3-...

Collapse
 
calvellido profile image
Juan Valencia

This could be a guided start (in Scala):

scala-exercises.org/fp_in_scala/ge...

There, the FP concepts are explained through Scala, so you can take the specific Scala syntax related too, if you need to.

Collapse
 
jj profile image
Juan Julián Merelo Guervós

You might want to give Perl6 a try. Although it's not purely functional, it does have the full range of functional structures. Plus you can do things procedurally if you want to. It's a great language, anyway.

Collapse
 
eljayadobe profile image
Eljay-Adobe

There are lots of functional programming languages to choose from. The "best" one depends on your interests.

Since you have used C#, you have familiarity with .NET. I presume you have Visual Studio or Xamarin IDE on hand.

F# ought to be a good choice.

I've read a lot of F# books. The one I recommend to get your bearings with F# is The Book of F# by Dave Fancher.

In my opinion, it is a really good book for F# as a tutorial and hand-holding book. Different people learn in different ways, and this book fit very well with my learning style.

When I learned F#, I used Xamarin and Mono, on Macintosh. But I have experience with Visual Studio as well, and F# is definitely a first-class language in the .NET ecosystem.