This year was my very first attendance at the Functional Conf and wow, what an experience it was, worth every minute! I learnt something from almost all of the talks I attended, and I am pretty sure that the other talks which I could not attend would’ve been full of learnings too. So here is my summary of the talks I attended.
Day 1
First was a talk from Richard Feldman titled “The Essence of Functional Programming” during which he explained the difference between lexical (closer to the definition site) vs. dynamic (closer to the usage site) binding. If you don’t know the difference between these, then check the following code between JS vs. Scala and you’ll understand the difference 🤓. The point – most of the modern languages go with lexical closures these days.
A JS example –
var suffix = "!";
let exclaim = (str) => {
return str + suffix;
};
exclaim("hello");
var suffix = "???";
exclaim("hello");
The same program in Scala –
var suffix = "!"
def exclaim = (s: String) => s"$s$suffix"
exclaim("hello")
var suffix = "???"
exclaim("hello")
And his final advice – avoid mutations and avoid side effects.
Then came Bartosz Milewski’s “Teaching Optics through Conspiracy Theories” another amazing talk which talks about Lenses and/or Optics – this is a little advanced topic in itself so if you are interested then please watch this talk.
Then was John Azariah’s “Nature-Inspired Optimization Algorithms with F#” and not just the algorithms he showed were cool, but the kind of code which you can write in F# is cooler 😉 Again a must watch talk.
Then came the most difficult decision making moment for me, where I had to choose between Debasish Ghosh’s “Functional Programming patterns for designing modular abstractions” vs. Alfonso Garcia-Caro’s “Beyond: Crossing the Platform Boundaries with F# and Fable” and although I use Scala at work I chose the latter because frankly F# attracts me more than Scala (these days) because –
(1) It looks like, eventually F# will enable me (a programmer) to use the language in many more contexts (UI, both web and mobile, data-science(y) tasks and others)
(2) Learning languages which are members of a family e.g. ML (OCaml, ReScript) or Lisp (Clojure, Racket) etc. is much more beneficial than learning a language with a completely new syntax (like Scala). I guess that’s the reason why Scala is gravitating towards indentation sensitive syntax to appeal more to Python programmers
And, if you don’t trust me on (1) above, then watch Alfonso’s talk and be prepared to be blown away 🤯. The spoiler – Fable already allows you to compile F# to JS, but work is ongoing to compile it to PHP, Python, Rust and Dart !!! Thank you F#🤩and Alfonso mentions in his talk that learning a new ecosystem, new tools is much harder than it seems, so thank you Alfonso and others for trying to make our lives easier. BTW, there is another exciting ongoing effort to compile Clojure to Dart 🤩
I’ll definitely watch Debasish’s talk later and you must too (specially if you are a Scala programmer).
Then was Luca Mugnaini’s “Familiarity or Guarantees? Functional Programming for the front-end” talk which clearly makes the case about using Elm for the front-end and how it benefited them immensely.
The following talk from Adam Granicz, “Re-targeting F# for the web: from JS to WebAssembly” makes another persuasive point about how you, as a developer, and how various companies can’t go wrong with adopting F#.
Ayush Mittal’s “Type classes in Scala 3” was another practical talk about the advantages of Scala 3 over the older versions. Definitely, Scala 3 will enable greater productivity, but sadly, one has to spend time in learning new syntax, new concepts.
Mey Beisaron’s “Multiplayer Online Game in Clojure: Attack of the Clones” was a fun talk to attend which underlines the simplicity of solutions written in Clojure, which, in turn enables higher productivity.
As per my opinion, one can use F# or Clojure for more wide ranging tasks than Scala (at least, that's the situation right now). There is Scala.js but it's adoption seems less widespread than ClojureScript or the F# counterparts (Fable, SAFE stack, WebSharper and others combined).
Dean Wampler’s keynote, “Lessons Learned from 15 Years of Scala in the Wild” was another excellent one with a poignant question about whether FP adoption will continue to grow? And his answer sadly, is No and he thinks that either it will decline over time or at least the growth will mostly stall, because (in Dean’s words) –
(1) For most of the world’s developers, FP is either too hard or they lack the motivation to learn it (I can attest the point about it being hard – I haven’t been able to fully grok advanced Scala libraries like Cats, Cats Effect or ZIO, even after having 20+ years programming experience and 3+ years of Scala experience – I definitely understand bits and pieces of these frameworks but haven’t been able to use these broadly in my day-to-day work)
(2) In contrast, OOP is “naively” intuitive and therefore seductive
(3) Data science people who are domain experts in Statistics etc. but not so much in programming (or FP) and they mostly write small and focused code (scripts in Python & R)
And finally, Dave Yarwood’s “Clojure through the lens of music” was the perfect talk to end day one with some soothing music as the output of the examples he presented using his super-fun, super-cool alda-clj library. Hats off Dave for this ultra enjoyable library – I’ll have to produce some music now 🎹. One must watch this talk to understand how REPL-driven development in Clojure differs from other languages which support a REPL.
Day 2
Day 2 started with a bang 💥with Adam Rosien’s “Concurrent State Machines with Cats Effect” talk. Now, I’ve been struggling to grok these advanced typed FP libraries in the Scala ecosystem (as mentioned above) for some time but I was itching to try out the code ⌨️he was showing in his slides! Judging by his talk, I can safely say that his book Essential Effects would be awesome too.
Then came another informative talk by Nikhil Barthwal “Implementing Event-Driven Microservices architecture in Functional language” with examples in F#. Since we are writing micro-services using Lagom at work, this talk reinforced a lot of the concepts I knew by improving my understanding about those, and at the same time imparting fresh knowledge about other concepts.
Then I watched Tony Morris’ “Type-hole development” and although I don’t use or haven’t looked much into Haskell, the examples he was solving and dishing out techniques to solve those problems as a skillful master was a joy to look at. A must watch talk if you are into Haskell.
Then came another highlight of the day for me with Joydeep Banik Roy’s “Free Based DSLs For Distributed Compute Engines” talk – mind totally blown away🤯by learning how they’ve used Free Monads to create Zeoflow, a unified data processing DSL and how they’ve managed to abstract away compute engines like Apache Spark and Beam 🎯. I think I finally understand Free Monads now and I might be able to create my own (little) DSL 🤞. BTW, if you happen to use Spark through Scala, then you must check out Zeotap’s spark-property-tests library.
Grahame Dixon’s “Extending Railway Oriented Programming in Elm to Make Complex User Flows Simple” talk was another informative one. I think I first read this term Railway Oriented Programming in Scott Wlaschin’s F# for fun and profit blog posts but it was long ago and had totally forgotten what it is, so it was a good refresher.
Then came another wow talk by Allister Beharry on “The Z3 SMT solver and functional programming” – I had no idea of SMT solvers and the examples he showed using F# quotations were mind blowing 🤓. I must learn some meta-programming using either Clojure macros or F# quotations or both. The code looked very similar to its Python counterpart largely because of the use of quotations. Again, a must watch talk for F# lovers.
Then came another learning heavy talk by Michael Pilquist on “fs2.Chunk” – a data structure that powers the fs2 (Functional Streams for Scala) streaming library. I thought I’ll get to see some examples on how to use fs2 but Michael instead talked about the design of Chunk and in particular, how design constraints guided its evolution. There were so many things to learn about Scala and data structures in general, from this talk.
And finally, the icing on the cake was the final keynote by Bruce Tate & Francesco Cesarini “Navigating the loop in water, on land and in programming models” 🛥️- I couldn’t have imagined before that such a talk is even possible. A fun and practical mix of real life issues and situations mapped to the world of programming; sort of like weaving two stories together with a common pitch.
All in all, a conference with a potpourri of talks using various programming languages, ranging in depth, breadth and fun. If you haven’t attended any Functional Conference before then make sure to not miss the next edition. You’ll be glad that you took my advice. And don’t just take my word on this, but better yet, watch the videos on the Fn Conf YouTube channel.
Thanks to Naresh Jain @nashjain and the entire team of organizers for the overall meaningful experience spread over 2 days and thanks to the speakers not just for sharing their knowledge but keeping us excited about the journey ahead.