/dev/reading
Category

Functional Programming

18 books, 2 subcategories
Order by
View
Augumenting Object-Oriented Java Code with Functional Principles
by Ben Weidig

Java developers usually tackle the complexity of software development through object-oriented programming (OOP). But not every problem is a good match for OOP. The functional programming (FP) paradigm offers you another approach to solving problems, and Java provides easy-to-grasp FP tools such as lambda expressions and Streams. If you're interested in applying FP concepts to your Java code, this book is for you.

Author Ben Weidig highlights different aspects of functional programming and shows you how to incorporate them into your code without going "fully functional." You'll learn how, when, and why to use FP concepts such as immutability and pure functions to write more concise, reasonable, and future-proof code. Many developers seek to expand their horizons by using OOP and FP together. It's no longer either-or; it's both.

In this book, you will:

  • Get a high-level overview of functional programming, including the types already available to Java developers
  • Explore different FP concepts and learn how to use them
  • Learn how to augment your code and use Java's new functional features in your daily work without going fully functional
  • Develop a functional mindset and improve your programming skills regardless of language or paradigm
by Paul Graham

ANSI Common Lisp combines an introduction to Lisp programming, and a convenient, up-to-date reference manual for ANSI Common Lisp. Beginners will find that its careful explanations and interesting examples make Lisp programming easy to learn. Professional programmers will appreciate its thorough, practical approach.

FEATURES:

  • An up-to-date reference manual for ANSI Common Lisp.
  • An in-depth look at object-oriented programming. Explains the Common Lisp Object System (CLOS), and also shows how to write your own object-oriented language.
  • Over 20 substantial examples, including programs for ray-tracing, text generation, pattern-matching, logical inference, generating HTML, sorting and searching, file I/O, compression, and date arithmetic.
  • Special attention to critical concepts, including prefix syntax, code vs. data, recursion, functional programming, types, implicit pointers, dynamic allocation, closures, macros, class precedence, and generic functions vs. message-passing.
  • A complete guide to optimization.
  • The clearest and most thorough explanation of macros in any introductory book.
  • Examples that illustrate Lisp programming styles, including rapid prototyping, bottom-up programming, object-oriented programming, and embedded languages.
  • An appendix on debugging, with examples of common errors.
Principles, Patterns, and Practices
by Robert C. Martin

A Practical Guide to Better, Cleaner Code with Functional Programming

In Functional Design, renowned software engineer Robert C. Martin ("Uncle Bob") explains how and why to use functional programming to build better systems for real customers. Martin compares conventional object-oriented coding structures in Java to those enabled by functional languages, identifies the best roles for each, and shows how to build better systems by judiciously using them in context.

Martin's approach is pragmatic, minimizing theory in favor of "in the-trenches" problem-solving. Through accessible examples, working developers will discover how the easy-to-learn, semantically rich Clojure language can help them improve code cleanliness, design, discipline, and outcomes. Martin examines well-known SOLID principles and Gang of Four Design Patterns from a functional perspective, revealing why patterns remain extremely valuable to functional programmers, and how to use them to achieve superior results.

  • Understand functional basics: immutability, persistent data, recursion, iteration, laziness, and statefulness
  • Contrast functional and object approaches through expertly crafted case studies
  • Explore functional design techniques for data flow
  • Use classic SOLID principles to write better Clojure code
  • Master pragmatic approaches to functional testing, GUIs, and concurrency
  • Make the most of design patterns in functional environments
  • Walk through building an enterprise-class Clojure application
by Enrico Buonanno

Real world examples and practical techniques for functional programming in C# without the jargon and theory.

In Functional Programming in C#, Second Edition you will learn how to:

  • Use higher-order functions to reduce duplication and do more with less code
  • Use pure functions to write code that is easy to test and optimize
  • Write pleasant APIs that accurately describe your program's behavior
  • Use dedicated types to handle nullability, system errors, and validation rules predictably and elegantly
  • Write composable code without the overhead of an IoC container

Functional Programming in C# has helped thousands of developers apply functional thinking to C# code. Its practical examples and spot-on treatment of FP concepts makes it the perfect guide for proficient C# programmers. This second edition is fully revised to cover new functional-inspired features in the most recent releases of C#, including tuples, async streams, pattern matching, and records. Each chapter is packed with awesome perspectives and epiphany moments on how functional programming can change the way you code.

How functional techniques improve your Java programs
by Pierre-Yves Saumont

Functional Programming in Java teaches Java developers how to incorporate the most powerful benefits of functional programming into new and existing Java code. You'll learn to think functionally about coding tasks in Java and use FP to make your applications easier to understand, optimize, maintain, and scale.

How to improve your JavaScript programs using functional techniques
by Luis Atencio

Functional Programming in JavaScript teaches JavaScript developers functional techniques that will improve extensibility, modularity, reusability, testability, and performance. Through concrete examples and jargon-free explanations, this book teaches you how to apply functional programming to real-life development tasks

by Marco Vermeulen, Rúnar Bjarnason and Paul Chiusano

Master techniques and concepts of functional programming to deliver safer, simpler, and more effective Kotlin code.

In Functional Programming in Kotlin you will learn:

  • Functional programming techniques for real-world applications
  • Write combinator libraries
  • Common structures and idioms in functional design
  • Simplicity and modularity (and fewer bugs!)

Functional Programming in Kotlin is a reworked version of the bestselling

Functional Programming in Scala, with all code samples, instructions, and exercises translated into the powerful Kotlin language. In this authoritative guide, you’ll take on the challenge of learning functional programming from first principles. Complex concepts are demonstrated through exercises that you’ll love to test yourself against. You’ll start writing Kotlin code that’s easier to read, easier to reuse, better for concurrency, and less prone to bugs and errors.

by Michael Pilquist, Rúnar Bjarnason and Paul Chiusano

This international bestseller has been revised with new exercises, annotations, and full coverage of Scala 3.

In Functional Programming in Scala, Second Edition you will learn how to:

  • Recognize and write purely functional code
  • Work with errors without using exceptions
  • Work with state and concurrency
  • Interact with functional structures that define common behaviors
  • Write code that performs I/O without sacrificing functional programming

Functional Programming in Scala has helped over 30,000 developers discover the power of functional programming. You’ll soon see why reviewers have called it “mindblowing”! The book smooths the complexity curve of functional programming, making it simple to understand the basics and intuitive to progress to more advanced topics. Concrete examples and exercises show you FP in the real world and reveal how it can improve your everyday coding practices. This second edition comes packed with the latest standards of FP, as well as full code updates to Scala 3, and its new language features.

by Will Kurt

Get Programming with Haskell introduces you to the Haskell language without drowning you in academic jargon and heavy functional programming theory. By working through 42 easy-to-follow lessons, you'll learn Haskell the best possible way—by doing Haskell!

by Michał Płachta

There’s no need to fear going functional! This friendly, lively, and engaging guide is perfect for any perplexed programmer. It lays out the principles of functional programming in a simple and concise way that will help you grok what FP is really all about.

In Grokking Functional Programming you will learn:

  • Designing with functions and types instead of objects
  • Programming with pure functions and immutable values
  • Writing concurrent programs using the functional style
  • Testing functional programs
  • Multiple learning approaches to help you grok each new concept

If you’ve ever found yourself rolling your eyes at functional programming, this is the book for you. Open up Grokking Functional Programming and you’ll find functional ideas mapped onto what you already know as an object-oriented programmer. The book focuses on practical aspects from page one. Hands-on examples apply functional principles to everyday programming tasks like concurrency, error handling, and improving readability. Plus, puzzles and exercises let you think and practice what you're learning. You’ll soon reach an amazing “aha” moment and start seeing code in a completely new way.

by Vitaly Bragilevsky

Turn the corner from “Haskell student” to “Haskell developer.”

Haskell in Depth explores the important language features and programming skills you’ll need to build production-quality software using Haskell. And along the way, you’ll pick up some interesting insights into why Haskell looks and works the way it does. Get ready to go deep!

Learn to Program in Lisp, One Game at a Time!
by Conrad Barski

Lisp has been hailed as the world’s most powerful programming language, but its cryptic syntax and academic reputation can be enough to scare off even experienced programmers. Those dark days are finally over—Land of Lisp brings the power of functional programming to the people!

With his brilliantly quirky comics and out-of-this-world games, longtime Lisper Conrad Barski teaches you the mysteries of Common Lisp. You’ll start with the basics, like list manipulation, I/O, and recursion, then move on to more complex topics like macros, higher order programming, and domain-specific languages. Then, when your brain overheats, you can kick back with an action-packed comic book interlude!

Along the way you’ll create (and play) games like Wizard Adventure, a text adventure with a whiskey-soaked twist, and Grand Theft Wumpus, the most violent version of Hunt the Wumpus the world has ever seen.

You'll learn to:

  • Master the quirks of Lisp’s syntax and semantics
  • Write concise and elegant functional programs
  • Use macros, create domain-specific languages, and learn other advanced Lisp techniques
  • Create your own web server, and use it to play browser-based games
  • Put your Lisp skills to the test by writing brain-melting games like Dice of Doom and Orc Battle

With Land of Lisp, the power of functional programming is yours to wield.

A Hands-on Guide to Exploring Physics with Haskell
by Scott N. Walck

Learn Physics with Functional Programming is your key to unlocking the mysteries of theoretical physics by coding the underlying math in Haskell.

You’ll use Haskell’s type system to check that your code makes sense as you deepen your understanding of Newtonian mechanics and electromagnetic theory, including how to describe and calculate electric and magnetic fields.

As you work your way through the book’s numerous examples and exercises, you’ll learn how to:

  • Encode vectors, derivatives, integrals, scalar fields, vector fields, and differential equations
  • Express fundamental physical principles using the logic of Haskell’s type system to clarify Newton’s second law, Coulomb’s law, the Biot-Savart law, and the Maxwell equations
  • Use higher-order functions to express numerical integration and approximation methods, such as the Euler method and the finite-difference time-domain (FDTD) method
  • Create graphs, models, and animations of physical scenarios like colliding billiard balls, waves in a guitar string, and a proton in a magnetic field Whether you’re using this book as a core textbook for a computational physics course or for self-study, Learn Physics with Functional Programming will teach you how to use the power of functional programming to explore the beautiful ideas of theoretical physics.
A Beginner's Guide
by Miran Lipovača

It's all in the name: Learn You a Haskell for Great Good! is a hilarious, illustrated guide to this complex functional language. Packed with the author's original artwork, pop culture references, and most importantly, useful example code, this book teaches functional fundamentals in a way you never thought possible.

You'll start with the kid stuff: basic syntax, recursion, types and type classes. Then once you've got the basics down, the real black belt master-class begins: you'll learn to use applicative functors, monads, zippers, and all the other mythical Haskell constructs you've only read about in storybooks.

As you work your way through the author's imaginative (and occasionally insane) examples, you'll learn to:

  • Laugh in the face of side effects as you wield purely functional programming techniques
  • Use the magic of Haskell's "laziness" to play with infinite sets of data
  • Organize your programs by creating your own types, type classes, and modules
  • Use Haskell's elegant input/output system to share the genius of your programs with the outside world

Short of eating the author's brain, you will not find a better way to learn this powerful language than reading Learn You a Haskell for Great Good!

Advanced Techniques for Common Lisp
by Paul Graham

Starting in the 1980s, Lisp began to be used in several large systems, including Emacs, Autocad, and Interleaf. On Lisp explains the reasons behind Lisp's growing popularity as a mainstream programming language. On Lisp is a comprehensive study of advanced Lisp techniques, with bottom-up programming as the unifying theme. It gives the first complete description of macros and macro applications. The book also covers important subjects related to bottom-up programming, including functional programming, rapid prototyping, interactive development, and embedded languages. The final chapter takes a deeper look at object-oriented programming than previous Lisp books, showing the step-by-step construction of a working model of the Common Lisp Object System (CLOS). As well as an indispensable reference, On Lisp is a source of software. Its examples form a library of functions and macros that readers will be able to use in their own Lisp programs.

From Strings to Turing Machines
by James W. Stelly

At last, a lively guided tour through all the features, functions, and applications of the Racket programming language. You’ll learn a variety of coding paradigms, including iterative, object oriented, and logic programming; create interactive graphics, draw diagrams, and solve puzzles as you explore Racket through fun computer science topics—from statistical analysis to search algorithms, the Turing machine, and more.

Early chapters cover basic Racket concepts like data types, syntax, variables, strings, and formatted output. You’ll learn how to perform math in Racket’s rich numerical environment, and use programming constructs in different problem domains (like coding solutions to the Tower of Hanoi puzzle). Later, you’ll play with plotting, grapple with graphics, and visualize data. Then, you’ll escape the confines of the command line to produce animations, interactive games, and a card trick program that’ll dazzle your friends.

You'll learn how tot:

  • Use DrRacket, an interactive development environment (IDE) for writing programs
  • Compute classical math problems, like the Fibonacci sequence
  • Generate two-dimensional function plots and create drawings using graphics primitives
  • Import and export data to and from Racket using ports, then visually analyze it
  • Build simple computing devices (pushdown automaton, Turing machine, and so on) that perform tasks
  • Leverage Racket’s built-in libraries to develop a command line algebraic calculator

Racket Programming the Fun Way is just like the language itself—an embodiment of everything that makes programming interesting and worthwhile, and that makes you a better programmer.

Learn to Program, One Game at a Time!
by Matthias Felleisen, David Van Horn and Conrad Barski

Racket is a descendant of Lisp, a programming language renowned for its elegance, power, and challenging learning curve. But while Racket retains the functional goodness of Lisp, it was designed with beginning programmers in mind. Realm of Racket is your introduction to the Racket language.

In Realm of Racket, you'll learn to program by creating increasingly complex games. Your journey begins with the Guess My Number game and coverage of some basic Racket etiquette. Next you'll dig into syntax and semantics, lists, structures, and conditionals, and learn to work with recursion and the GUI as you build the Robot Snake game. After that it's on to lambda and mutant structs (and an Orc Battle), and fancy loops and the Dice of Doom. Finally, you'll explore laziness, AI, distributed games, and the Hungry Henry game.

As you progress through the games, chapter checkpoints and challenges help reinforce what you've learned. Offbeat comics keep things fun along the way.

As you travel through the Racket realm, you'll:

  • Master the quirks of Racket's syntax and semantics
  • Learn to write concise and elegant functional programs
  • Create a graphical user interface using the 2htdp/image library
  • Create a server to handle true multiplayer games

Realm of Racket is a lighthearted guide to some serious programming. Read it to see why Racketeers have so much fun!

by Edwin Brady

Type-Driven Development with Idris, written by the creator of Idris, teaches you how to improve the performance and accuracy of your programs by taking advantage of a state-of-the-art type system. This book teaches you with Idris, a language designed to support type-driven development.