Jonathan Müller

Functional Programming in C++

What do ranges, error handling, and I/O have in common? A single functional concept that simplifies complex C++ systems.

Functional Programming in C++
#1about 3 minutes

Understanding functional programming principles in C++

Functional programming is a declarative style that eliminates state to reduce bugs, and C++ allows combining its benefits with imperative performance.

#2about 4 minutes

Building lazy data pipelines with C++20 ranges and views

Use `std::ranges` and views like `transform` and `filter` to create lazy, state-free data processing pipelines that avoid intermediate allocations.

#3about 8 minutes

Solving complex problems with advanced range adaptors

Leverage powerful range adaptors like `cartesian_product` for combinations and `chunk_by` for splitting sequences based on a predicate.

#4about 6 minutes

Creating composable error handling with `std::expected`

Model failures as values using `std::expected` to build clear, functional error handling pipelines with `transform` and `and_then`.

#5about 4 minutes

Separating IO from computation using deferred actions

Isolate side effects by composing IO operations as declarative actions, a pattern that mirrors the upcoming C++26 senders and receivers framework.

#6about 2 minutes

Understanding monads as a unifying composition pattern

Recognize that ranges, `std::expected`, and IO actions are all monads, sharing a common interface for composition with `transform` and `and_then`.

Related jobs
Jobs that call for the skills explored in this talk.

Featured Partners

Related Articles

View all articles
CH
Chris Heilmann
All the videos of Halfstack London 2024!
Last month was Halfstack London, a conference about the web, JavaScript and half a dozen other things. We were there to deliver a talk, but also to record all the sessions and we're happy to share them with you. It took a bit as we had to wait for th...
All the videos of Halfstack London 2024!
BR
Benjamin Ruschin
What Developers Really Need to Create Great Code Demos
Every developer on earth has, at some point, had another developer to thank for a breakthrough, a success, an aha moment they wouldn’t have had without coming across that blog post, that open-source contribution, that reply on socials or that humble ...
What Developers Really Need to Create Great Code Demos
DC
Daniel Cranney
Dev Digest 188: CfP time, the risks of NPM and IKEA algorithms
Inside last week’s Dev Digest 188 . 🤖 GitHub Copilot CLI is now in public review 💻 Microsoft is bringing ‘vibe working’ to office apps 🎣 Attackers abuse AI tools to generate captchas in fishing attacks ⚠️ When LLMs autonomously attack 🧠 Common cause...
Dev Digest 188: CfP time, the risks of NPM and IKEA algorithms

From learning to earning

Jobs that call for the skills explored in this talk.

Rust and GoLang

Rust and GoLang

NHe4a GmbH
Karlsruhe, Germany

Remote
55-65K
Intermediate
Senior
Go
Rust