Book description
Explore functional programming and discover new ways of thinking about code. You know you need to master functional programming, but learning one functional language is only the start. In this book, through articles drawn from PragPub magazine and articles written specifically for this book, you'll explore functional thinking and functional style and idioms across languages. Led by expert guides, you'll discover the distinct strengths and approaches of Clojure, Elixir, Haskell, Scala, and Swift and learn which best suits your needs.
Contributing authors: Rich Hickey, Stuart Halloway, Aaron Bedra, Michael Bevilacqua-Linn, Venkat Subramaniam, Paul Callaghan, Jose Valim, Dave Thomas, Natasha Murashev, Tony Hillerson, Josh Chisholm, and Bruce Tate.
Functional programming is on the rise because it lets you write simpler, cleaner code, and its emphasis on immutability makes it ideal for maximizing the benefits of multiple cores and distributed solutions. So far nobody's invented the perfect functional language - each has its unique strengths. In Functional Programming: A PragPub Anthology, you'll investigate the philosophies, tools, and idioms of five different functional programming languages.
See how Swift, the development language for iOS, encourages you to build highly scalable apps using functional techniques like map and reduce. Discover how Scala allows you to transition gently but deeply into functional programming without losing the benefits of the JVM, while with Lisp-based Clojure, you can plunge fully into the functional style. Learn about advanced functional concepts in Haskell, a pure functional language making powerful use of the type system with type inference and type classes. And see how functional programming is becoming more elegant and friendly with Elixir, a new functional language built on the powerful Erlang base.The industry has been embracing functional programming more and more, driven by the need for concurrency and parallelism. This collection of articles will lead you to mastering the functional approach to problem solving. So put on your explorer's hat and prepare to be surprised. The goal of exploration is always discovery.What You Need:
Familiarity with one or more programming languages.Publisher resources
Table of contents
-  Introduction
-  Acknowledgements
- Part I. The Functional Paradigm
- Part II. Scala: A Hybrid Language
- Part III. Clojure: The New Lisp
- Part IV. Elixir: Making Programming Fun Again
- Part V. Haskell: The Researcher’s Playground
- Part VI. Swift: Functional Programming for Mobile Apps
-
Part VII. Going Deeper
- 17. Protocols in Swift vs. Ruby and Elixir
- 18. Pattern Matching in Scala
- 19. Concurrency in Scala
- 20. Clojure’s Exceptional Handling of ExceptionsClojure’s Exceptional Handling of Exceptions
- 21. A Testing Framework for Elixir
- 22. Building Test Data with Elixir
-
23. Haskell’s Type SystemHaskell’s Type System
- TL;DR
- What Are Types For?
- A Concrete Example: Sorting
- The Language of Haskell’s Type System
- Type Inference and Type Checking
- Some Examples
- Comfort Break
- Interfaces and Type Classes
- Some Real-World Examples with Interfaces
- Pros and Cons—the 80/20 Rule
- Beyond Haskell: Dependent Types
- Propositions Are Types, and Proofs Are Programs
- Another Look at Sorting
- Back to Earth
- 24. A Haskell Project: Testing Native Code
- 25. The Many Faces of Swift Functions
- 26. A Functional Approach to Lua
- A1. Meet the Authors
-  Bibliography
Product information
- Title: Functional Programming: A PragPub Anthology
- Author(s):
- Release date: July 2017
- Publisher(s): Pragmatic Bookshelf
- ISBN: 9781680502336
You might also like
book
Grokking Algorithms
Grokking Algorithms is a friendly take on this core computer science topic. In it, you'll learn …
book
The Rust Programming Language (Covers Rust 2018)
The Rust Programming Language is the official book on Rust: an open source systems programming language …
book
Modern Java in Action
Modern Java in Action connects new features of the Java language with their practical applications. Using …
book
Python Crash Course, 2nd Edition
This is the second edition of the best selling Python book in the world. Python Crash …