Recommended.
This book is a history of lambdas in C++. It starts off with C++98/C++03, discussing callable objects. It quickly moves to C++11 which introduced Lambdas and moves on to detail Lambdas in C++14, C++17, and finally C++20. Better C++ developers than I have critiqued the book from an expert’s point of view. This review is from the perspective of a not-quite-a-beginner and definitely not an expert point of view. The author has a blog, and has written additional C++ articles which are archived here: https://www.cppstories.com/p/archive/.
I had no idea that lambdas could be so intricate with many arcane abilities. This book is an inexpensive tome that covers a lot of what lambdas can do and how to do it, covering a broad selection of C++ standards and how to avoid common mistakes (typically dealing with stale references or concurrency issues).
I recommend that potential readers consult the book’s website for a more detailed overview of the book. That site has a FAQ about the book, in particular it discusses whether or not the book is suitable for you. In particular, this book is aimed at readers who are somewhere between ‘not a beginner nor an expert’. I fit in the lower end of that bracket and, as a result, found some of the later chapters surprising and challenging. That is a good thing.
To quote an English teacher of mine, ask “what, how, why”. I felt that this book covered “what and how” very well but in some circumstances, I struggled to know the why certain advanced techniques were in use compared to more simpler alternatives.
Website: https://leanpub.com/cpplambda
Code Site: https://github.com/fenbf/cpplambdastory-code










