Functional Thinking: Paradigm Over Syntax
If you’re familiar with functional programming basics and want to gain a much deeper understanding, this in-depth guide takes you beyond syntax and demonstrates how you need to think in a new way. Software architect Neal Ford shows intermediate to advanced developers how functional coding allows you to step back a level of abstraction so you can see your programming problem with greater clarity.

Each chapter shows you various examples of functional thinking, using numerous code examples from Java 8 and other JVM languages that include functional capabilities. This book may bend your mind, but you’ll come away with a much better grasp of functional programming concepts.

  • Understand why many imperative languages are adding functional capabilities
  • Compare functional and imperative solutions to common problems
  • Examine ways to cede control of routine chores to the runtime
  • Learn how memoization and laziness eliminate hand-crafted solutions
  • Explore functional approaches to design patterns and code reuse
  • View real-world examples of functional thinking with Java 8, and in functional architectures and web frameworks
  • Learn the pros and cons of living in a paradigmatically richer world

If you’re new to functional programming, check out Josh Backfield’s book Becoming Functional.

1119920603
Functional Thinking: Paradigm Over Syntax
If you’re familiar with functional programming basics and want to gain a much deeper understanding, this in-depth guide takes you beyond syntax and demonstrates how you need to think in a new way. Software architect Neal Ford shows intermediate to advanced developers how functional coding allows you to step back a level of abstraction so you can see your programming problem with greater clarity.

Each chapter shows you various examples of functional thinking, using numerous code examples from Java 8 and other JVM languages that include functional capabilities. This book may bend your mind, but you’ll come away with a much better grasp of functional programming concepts.

  • Understand why many imperative languages are adding functional capabilities
  • Compare functional and imperative solutions to common problems
  • Examine ways to cede control of routine chores to the runtime
  • Learn how memoization and laziness eliminate hand-crafted solutions
  • Explore functional approaches to design patterns and code reuse
  • View real-world examples of functional thinking with Java 8, and in functional architectures and web frameworks
  • Learn the pros and cons of living in a paradigmatically richer world

If you’re new to functional programming, check out Josh Backfield’s book Becoming Functional.

39.99 In Stock
Functional Thinking: Paradigm Over Syntax

Functional Thinking: Paradigm Over Syntax

by Neal Ford
Functional Thinking: Paradigm Over Syntax

Functional Thinking: Paradigm Over Syntax

by Neal Ford

Paperback

$39.99 
  • SHIP THIS ITEM
    In stock. Ships in 1-2 days.
  • PICK UP IN STORE

    Your local store may have stock of this item.

Related collections and offers


Overview

If you’re familiar with functional programming basics and want to gain a much deeper understanding, this in-depth guide takes you beyond syntax and demonstrates how you need to think in a new way. Software architect Neal Ford shows intermediate to advanced developers how functional coding allows you to step back a level of abstraction so you can see your programming problem with greater clarity.

Each chapter shows you various examples of functional thinking, using numerous code examples from Java 8 and other JVM languages that include functional capabilities. This book may bend your mind, but you’ll come away with a much better grasp of functional programming concepts.

  • Understand why many imperative languages are adding functional capabilities
  • Compare functional and imperative solutions to common problems
  • Examine ways to cede control of routine chores to the runtime
  • Learn how memoization and laziness eliminate hand-crafted solutions
  • Explore functional approaches to design patterns and code reuse
  • View real-world examples of functional thinking with Java 8, and in functional architectures and web frameworks
  • Learn the pros and cons of living in a paradigmatically richer world

If you’re new to functional programming, check out Josh Backfield’s book Becoming Functional.


Product Details

ISBN-13: 9781449365516
Publisher: O'Reilly Media, Incorporated
Publication date: 07/26/2014
Pages: 177
Product dimensions: 6.90(w) x 9.00(h) x 0.40(d)

About the Author

Neal is Director, Software Architect, and Meme Wrangler at ThoughtWorks, a global IT consultancy with an exclusive focus on end-to-end software development and delivery. Before joining ThoughtWorks, Neal was the Chief Technology Officer at The DSW Group, Ltd., a nationally recognized training and development firm.



Neal has a degree in Computer Science from Georgia State Universityspecializing in languages and compilers and a minor in mathematics specializing in statistical analysis. He is also the designer and developer of applications, instructional materials, magazine articles, and video presentations. He is also the author of 6 books, including the most recent Presentation Patterns and Functional Thinking. Given his degree, Neal is a bit of a language geek, with affections including but not limited to Ruby, Clojure, Java, Groovy, JavaScript, Scala and C#/.NET. His primary consulting focus is the design and construction of large-scale enterprise applications. Neal is an internationally acclaimed speaker, having spoken at over 300 developer conferences worldwide, delivering more than 2000 presentations. If you have an insatiable curiosity about Neal, visit his web site at nealford.com. He welcomes feedback and can be reached at nford@thoughtworks.com.

Table of Contents

Preface vii

1 Why 1

Shifting Paradigms 2

Aligning with Language Trends 4

Ceding Control to the Language/Runtime 4

Concision 5

2 Shift 11

A Common Example 11

Imperative Processing 11

Functional Processing 12

Case Study: Number Classification 17

Imperative Number Classification 17

Slightly More Functional Number Classification 19

Java 8 Number Classifier 21

Functional Java Number Classifier 22

Common Building Blocks 24

Filter 24

Map 25

Fold/Reduce 29

Synonym Suffering 31

Filter 31

Map 34

Fold/Reduce 36

3 Cede 39

Iteration to Higher-Order Functions 39

Closures 40

Currying and Partial Application 44

Definitions and Distinctions 44

In Groovy 45

In Clojure 47

Scala 47

Common Uses 51

Recursion 52

Seeing Lists Differently 52

Streams and Work Reordering 56

4 Smarter, Not Harder 59

Memoization 59

Caching 60

Adding Memoization 63

Laziness 70

Lazy Iterator in Java 70

Totally Lazy Number Classifier 72

Lazy Lists in Groovy 74

Building a Lazy List 77

Benefits of Laziness 80

Lazy Field Initialization 82

5 Evolve 83

Few Data Structures, Many Operations 83

Bending the Language Toward the Problem 85

Rethinking Dispatch 86

Improving Dispatch with Groovy 86

Clojure's "Bendable" Language 87

Clojure Multimethods and a la carte Polymorphism 89

Operator Overloading 91

Groovy 91

Scala 93

Functional Data Structures 95

Functional Error Handling 96

The Either Class 97

The Option Class 105

Either Trees and Pattern Matching 106

6 Advance 113

Design Patterns in Functional Languages 113

Function-Level Reuse 114

Template Method 116

Strategy 118

The Flyweight Design Pattern and Memoization 119

Factory and Currying 122

Structural Versus Functional Reuse 124

Code Reuse Via Structure 124

7 Practical Thinking 133

Java 8 135

Functional Interfaces 135

Optional 136

Java 8 Streams 136

Functional Infrastructure 137

Architecture 137

Web Frameworks 141

Databases 142

8 Polyglot and Polyparadigm 145

Combining Functional with Metaprogrammmg 146

Mapping Data Types with Metaprogrammmg 147

Infinite Streams with Functional Java and Groovy 148

Consequences of Multiparadigm Languages 150

Context Versus Composition 151

Functional Pyramid 154

Index 159

From the B&N Reads Blog

Customer Reviews