Hacker News Comments on
École Polytechnique Fédérale de Lausanne
Functional Programming Principles in Scala
Hacker News Stories and CommentsAll the comments and stories posted to Hacker News that reference this url.
The author's struggles with Haskell resonate. I suspect it's just a very hard language to learn. I've given up attempting to learn it at least twice now.
I took Martin Odersky's Scala MOOC sometime around 2012-2014 and it was easy. It just made sense and the IDE experience was nice. I would recommend it to anyone who uses C# or Java and wants to learn FP. Although after 8 years I don't know if it's still as good, or if something better has come along. Either way, the course is still available: https://www.coursera.org/learn/scala-functional-programming
Next I worked through SICP and that was the best CS book I've read, although significantly more difficult than the Scala course.
⬐ oderskyNote that the course got revamped this year. It is now based on Scala 3 and new content was added. Some of the new topics are: enums, extension methods, and givens.
If you haven’t done any functional programming I can recommend this course:
Functional Programming Principles in Scala https://www.coursera.org/learn/progfun1 on Coursera. It's taught by Martin Odersky, one of the language's creators. Very well organized, highly automated assignment testing (you submit via CLI). I went in wanting to learn Scala, but what I learned about FP has stayed with me for years. Even though I've moved on from Scala I'm a much better programmer for having taken that course.
Functional Programming Principles in Scala  taught by Martin Odersky, professor at EPFL and creator of the Scala language.
⬐ wongmaWould this course be appropriate for those with a lot of general programming (OOP) knowledge, but little to no FP experience?⬐ dragonwriter⬐ necrobritIMO, yes, very much.⬐ acjohnson55I'd go as far as to say that those folks would be the ideal audience.Seconded! Odersky is a great lecturer (and very practical lecturer despite Scalas "academic" reputation) and the course was very well organized.
I did the course on the first or second run however, not sure if it has been kept up to date or if it is still well run.
Was disappointed with the follow up courses though, the lecturers didn't live up to Odersky.⬐ andy_wroteI'm in the middle of auditing the Scala track on Courersa.
The first course was great. I agree that Odersky is a very good lecturer, organized and easy to follow. I'd recommend it to anyone interested in Scala.
The second course was OK but not quite as good, it felt a little less systematic. It was mostly Odersky, but for part of the final week the course switches tracks to a different lecturer who clearly was preparing slides for a different lecture series, and I thought both the lectures weren't as clear and the stitch-in of the different material wasn't handled smoothly.
I've just started the third and while it's not Odersky, the lecturers have been good so far.
There is a course on Coursera thaught by the Scala creator: https://www.coursera.org/learn/progfun1
⬐ gingerbread-manIt's actually a series of 4 courses, 5 if you include the "capstone project." I've watched a few of the videos-- it's pretty decent, but intended for those who don't have much experience with functional programming. The first course I believe is modeled off the Structure and Interpretation of Computer Programs.
I think the answer to this question really depends on where you're coming from. An experienced Java developer will need to focus on different things than someone who has spent the last decade hacking Common Lisp or OCaml.⬐ joncrocksI would agree and disagree.
The first course is the one that's dedicated to Scala the language, whereas the rest are more focused on reactive/parallel programming that happens to be in Scala.
The first course is good, and acts as a good introduction if you've encountered functional programming before.
The canonical source for learning Scala from scratch (at least, when I was learning a couple of years ago) is the Coursera course by Martin Odersky, one of the language's founders. It appears that the course has grown somewhat, but you can still find part 1 here: https://www.coursera.org/learn/progfun1
⬐ blacksmytheBrilliant course.
>> Coursera course by Martin Odersky
Unfortunately, the next one in the series is not nearly as good.⬐ dv35zI took the course - unfortunately, and to be honest, it didn't have the approachability and "fun" of Zed's books. To me - it felt very dry, academic, and quickly became a chore to complete rather than a joy. I need the version aimed for "C- python programmer" / newbie rather than "eager CS student" or "experienced Java dev".
I have suggested Odersky's introductory MOOC  to many of my students and they all thought it was great. It's heavily inspired by SICP, so it should be easy, given your background.
⬐ wpietriYes, I second the recommendation for the course. And I can happily recommend it for people who don't even plan to use Scala, but who just want to get a feel for functional vs OO approaches. Odersky sees them as complimentary, and in some sense Scala is his way of proving the point.
That's interesting. Just a few days ago with great regret I decided to drop the (free) Scala course on Coursera after almost finishing week #3 (of 5 I think). I'm actually already pretty familiar at least with the essentials of functional programming but would like to go even deeper.
However, I found the step too steep between the easy to understand lectures and the exercises, and the latter not as useful as they could be. It felt like I was suddenly dropped off and left to my own devices with no guidance. "Now implement this!" Uhm... what? Sure, that's easy, I've been implementing much more complicated things for decades. The problem is I have no idea how to approach it "the right way" as far as Scala is concerned, that's why I'm taking the course!
Looking at the forum - extremely sparsely populated even after over 4 months - showed that I could also expect no guidance from there. That meant that even when I finished a task I was unable to find out if what I had done was the right (functional) way. For one and most importantly, there is hardly anyone to respond, but also since the only exercises are the homework assignments you can't just post your code, that's an "honor code violation". There also is no "solution", i.e. you can't see how the course author(s) would have implemented it.
Another example, people in the forum complained about extreme differences in performance for very minor differences in the way you wrote something, and you had to find all of this out completely for yourself, again no guidance at all.
Another point is that I found the problems too academic. Sure, I can walk a list of head.tail or a tree of left.element.right tuples. But overall the problems were all from what I did a long time ago at university and it felt very, very far from what I deal with now - and I don't just do CRUD or other boring stuff and actually do have interesting algorithms to implement. The course feels like being made for university students - in a negative way.
Overall I found the course more frustration than it was worth. I could have solved the programming challenges easily enough in a way I already knew, but what's the point? I wanted to learn the new (Scala) way, but felt all alone in trying to do that.
The course was like a good violin player demonstrating a piece and then giving me some sheet music and shoving me out the door "come back when you can play that". It's hard to complain about "free", but if course forum participation is a guide, both total numbers as well as the steep drop-off after week 1 and 2, it isn't very successful.
The course: https://www.coursera.org/learn/progfun1
Note: Enrolling in the courses individually is possible for free, going through the "specialization" page at https://www.coursera.org/specializations/scala only shows the for-pay option.
⬐ the_afI actually liked the progfun1 course, which I took a few years ago. It's one of the cleanest courses I've taken on Coursera. It's true that it's slightly "academic", but that's what many introductions to functional programming often feel like.
However, the follow-up courses, Reactive Programming (retired) and Functional Program Design, are a total let down. They are a rip-off, especially if you paid for them: a complete mess, no relation between lectures and assignments, no introduction of new concepts in relation to a greater context, the slides are not proof-read, constant mentions to non-existent slides and lectures, repeat material from previous courses (a side-effect of the courses being mash-ups of previous material), and example code that doesn't type-check or compile. It's not any single mistake, but the aggregation of them all, and the feeling that the authors just don't care enough. Thankfully I didn't pay for this.
In my opinion, the gold standard for Coursera is Dan Grossman's excellent Programming Languages, which I fully recommend.⬐ yawaraminHave to say, I loved Dan Grossman's work teaching SML. Quite a few of those lecture videos had lightbulb moments for me.⬐ davnnI share the exact same story. Progfun is a really smooth introdu tion to FP in my opinion, no crazy syntax and only the core concepts. For any deeper concepts and if you don't understand what FP really means you should check out a purely functional language.⬐ NoseshineJust to clarify my opinion on progfun: The lectures are good.
The coding tasks could have been okay - if there was any guidance. I don't even get to see any sample solutions. So even if I make it work, I don't know if that is a good way to do it, the "functional", the "Scala way". And the performance issue I mentioned, it was a major one, the difference between the code even being usable for more than a thousand elements in the list or getting a stack overflow, and the difference was extremely minor, in one case the order in which you called "union" on sets. All of that had to be found out by the students, and even after they found out nobody really had a good idea or explanation for why it was so.
Also, there only was one (small!) opportunity to actually practice what you just learned per week - and that came without any feedback apart from "works/doesn't". Since the course was about a particular programming style that really wasn't enough.
How about https://www.coursera.org/learn/progfun1 ?
They are orthogonal. Program in Scala and do both.
"Functional Programming Principles in Scala" https://www.coursera.org/learn/progfun1
"Functional Program Design in Scala" https://www.coursera.org/learn/progfun2
(There are two more free courses in the "specialization" - only the certificates and the capstone project cost money - original announcement http://www.scala-lang.org/blog/2016/05/23/scala-moocs-specia...)
⬐ pekk"Program in Scala" is just promotion, not an answer to the question. There are more than a few languages which advertise the possibility of using both OO and functional styles.⬐ mafribeThat's correct, but in which other ones is the integration so smooth as in Scala?⬐ ridiculous_fishSwift, OCaml, F#, Common LISP?⬐ airless_barNo?⬐ ridiculous_fishI am not a Scala programmer. Can you please give some examples of how Scala integrates OO and FP better than other languages?