r/functionalprogramming • • Oct 16 '18

Question Path to learn functional programming

Background - After my internship, my supervisor told me that I needed to work on my program design and learning functional programming would be a step in the proper direction as it would force me to think in a particular way.

Steps taken - He suggested learning scala, but since it is not strictly functional I was not really "forced" to program in a functional style.

Programming Language Experience - Java, Python, Scala

Most functional programming language tutorials/books out there focus on the language and not "functional programming" (The language is always the easy part - It does not take that much time to pick it up).

I would love any suggestions on how to go about learning functional programming. Thanks.

36 Upvotes

24 comments sorted by

View all comments

9

u/spreadLink Oct 17 '18

Not to bash haskell, but I can not believe that, in a question specifically asking for non-language books, the haskell book gets recommended and SICP remains unmentioned.

You should try "Structure and Interpretation of computer Programs", it's free online and v v good.

It uses scheme as the teaching language, but really can be worked through with any language supporting basic recursion and higher order functions.
It will also not just teach functional programming, but generally good principles for writing good programs in any environment.

Also, don't be scared by the mathy examples in the beginning, they only look scary because of the Greek symbols.

Good luck.

2

u/daredevildas Oct 17 '18

Thoughts on "How to design programs" in place of SICP?

2

u/spreadLink Oct 17 '18

I have never read it so i can't say anything about it unfortunately, sorry. Hopefully someone else can jump in here, otherwise i'd recommend to ask in the /r/scheme or /r/Racket subreddits specifically for what they think about it.

Either way, i wish you good luck with your journey, and always remember to never follow the cargo cult too far into the caves ;)