𝔖 Scriptorium
✦   LIBER   ✦

πŸ“

Functional Programming in Kotlin by Tutorials

✍ Scribed by Massimo Carli


Year
2022
Tongue
English
Leaves
567
Category
Library

⬇  Acquire This Volume

No coin nor oath required. For personal study only.

✦ Table of Contents


What You Need
Book Source Code & Forums
Dedications
About the Team
About the Author
About the Editors
Introduction
How to read this book
Chapter 1: Why Functional Programming
Using a declarative approach
Higher-order functions
Composition
Pure functions and testability
Exception handling
Key points
Where to go from here?
Chapter 2: Function Fundamentals
What is a function?
Introduction to category theory
Category and logic
Initial and terminal objects
Category of types and functions
Do types and functions define a category?
Initial and terminal objects
Types and sets
Function types
Challenges
Key points
Where to go from here?
Chapter 3: Functional Programming Concepts
Pure functions
Why are pure functions important?
Referential transparency and the substitution model
Side effects
Challenges
Key points
Where to go from here?
Chapter 4: Expression Evaluation, Laziness & More About Functions
Expression evaluation order
Understanding lambda expressions
Lazy evaluation
Memoization
Create a lazy stream with Kotlin
Normal-order evaluation
Challenges
Key points
Where to go from here?
Chapter 5: Higher-Order Functions
Imperative vs. declarative approach
Higher-order functions
Functional interfaces
Using lambda expressions as input and output
Challenges
Key points
Where to go from here?
Chapter 6: Immutability & Recursion
Immutability
Immutability advantages
The price of immutability
Immutability and functional programming
Immutability and recursion
Challenges
Key points
Where to go from here?
Chapter 7: Functional Data Structures
Immutable data structure
Mutators
Why FList is a persistent data structure
Challenges
Key points
Where to go from here?
Chapter 8: Composition
Composition in Kotlin
Partial application
Compose functions with side effects
Compose mutation
Challenges
Key points
Where to go from here?
Chapter 9: Data Types
What is a data type?
The Optional data type
The List data type
What about FList?
The Either data type
Challenges
Key points
Where to go from here?
Chapter 10: Algebraic Data Types
What is algebra?
Data types and multiplication
Data types and addition
Putting algebra to work
Other algebraic properties
Fun with exponents
Using algebra with the List type
Key points
Where to go from here?
Chapter 11: Functors
What is a functor?
Functors in programming
Functor laws
The FList and List functors
Bifunctors
Typeclasses
Key points
Where to go from here?
Chapter 12: Monoids & Semigroups
What is a monoid?
Property-based testing
Monoids and foldable types
Monoids and category theory
The semigroup typeclass
Key points
Where to go from here?
Chapter 13: Understanding Monads
The road to monads!
A pragmatic definition of monad
Why monads?
Key points
Where to go from here?
Chapter 14: Error Handling With Functional Programming
Exception handling
Handling exception strategies
Applicative functor
The Kotlin Result data type
Meet the RayTV app
Key points
Where to go from here?
Chapter 15: Managing State
The problem
A practical example
Key points
Where to go from here?
Chapter 16: Handling Side Effects
From State to IO
The IO monad
The meaning of IO
Key points
Where to go from here?
Chapter 17: Sequence & Flow
The Sequence data type
The Flow data type
The SharedFlow & StateFlow data types
Key points
Where to go from here?
Chapter 18: Mobius β€” A Functional Reactive Framework
Mobius principles and concepts
The Mobius workflow
Build your app
Mobius loop in Android
Key points
Where to go from here?
Chapter 19: Arrow
Exceptions as side effects
Arrow optics
Arrow lenses
Key points
Where to go from here?
Conclusion
Appendix A: Chapter 1 Exercise Solutions
Exercise 1.1
Exercise 1.2
Appendix B: Chapter 2 Exercise & Challenge Solutions
Exercise 2.1
Exercise 2.2
Exercise 2.3
Exercise 2.4
Exercise 2.5
Challenge 1: Functions and sets
Challenge 2: Functions and set again
Challenge 3: The right domain
Appendix C: Chapter 3 Exercise & Challenge Solutions
Exercise 3.1
Exercise 3.2
Exercise 3.3
Exercise 3.4
Exercise 3.5
Challenge 1: Pure or impure?
Challenge 2: Pure or impure?
Challenge 3: Pure or impure?
Appendix D: Chapter 4 Exercise & Challenge Solutions
Exercise 4.1
Exercise 4.2
Exercise 4.3
Exercise 4.4
Exercise 4.5
Exercise 4.6
Challenge 4.1
Challenge 4.2
Appendix E: Chapter 5 Exercise & Challenge Solutions
Exercise 5.1
Exercise 5.2
Exercise 5.3
Exercise 5.4
Exercise 5.5
Challenge 5.1: Mapping is important
Challenge 5.2: Prime number filtering
Appendix F: Chapter 6 Exercise & Challenge Solutions
Exercise 6.1
Exercise 6.2
Exercise 6.3
Exercise 6.4
Challenge 6.1: Immutability and recursion
Challenge 6.2: Tail-recursive Fibonacci
Appendix G: Chapter 7 Exercise & Challenge Solutions
Exercise 7.1
Exercise 7.2
Exercise 7.3
Exercise 7.4
Exercise 7.5
Exercise 7.6
Exercise 7.7
Challenge 7.1
Challenge 7.2
Challenge 7.3
Appendix H: Chapter 8 Exercise & Challenge Solutions
Exercise 8.1
Exercise 8.2
Exercise 8.3
Exercise 8.4
Challenge 1: Callable stuff
Challenge 2: Parameters or not parameters?
Appendix I: Chapter 9 Exercise & Challenge Solutions
Exercise 9.1
Exercise 9.2
Exercise 9.3
Exercise 9.4
Exercise 9.5
Challenge 9.1: Filtering
Challenge 9.2
Challenge 9.3: Average
Challenge 9.4: Last
Appendix J: Chapter 10 Exercise Solutions
Exercise 10.1
Exercise 10.2
Exercise 10.3
Appendix K: Chapter 12 Exercise Solutions
Exercise 12.1
Exercise 12.2
Exercise 12.3
Exercise 12.4
Exercise 12.5
Appendix L: Chapter 13 Exercise Solutions
Exercise 13.1
Exercise 13.2
Appendix M: Chapter 14 Exercise Solutions
Exercise 14.1
Exercise 14.2


πŸ“œ SIMILAR VOLUMES


Functional Programming in Kotlin
✍ Marco Vermeulen, RΓΊnar Bjarnason, Paul Chiusano πŸ“‚ Library πŸ“… 2021 πŸ› Manning Publications 🌐 English

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

Functional Programming in Kotlin
✍ Marco Vermeulen, RΓΊnar Bjarnason, Paul Chiusano πŸ“‚ Library πŸ“… 2021 πŸ› Manning Publications 🌐 English

<b>Master techniques and concepts of functional programming to deliver safer, simpler, and more effective Kotlin code.</b> In <i>Functional Programming in Kotlin</i> you will learn: Β Β Β  Functional programming techniques for real-world applications Β Β Β  Write combinator libraries Β Β Β  Common

Functional Programming in Kotlin
✍ Marco Vermeulen, RΓΊnar Bjarnason, Paul Chiusano πŸ“‚ Library πŸ“… 2021 πŸ› Manning 🌐 English

<b>Master techniques and concepts of functional programming to deliver safer, simpler, and more effective Kotlin code.</b> In <i>Functional Programming in Kotlin</i> you will learn: Β Β Β  Functional programming techniques for real-world applications Β Β Β  Write combinator libraries Β Β Β  Common

Kotlin Coroutines by Tutorial: Mastering
✍ raywenderlich Tutorial Team, Filip BabiΔ‡, Nishant Srivastava πŸ“‚ Library πŸ“… 2019 πŸ› Razeware LLC 🌐 English

<h2>Learn Coroutines in Kotlin and Android!</h2><p>Executing background tasks has always been a big challenge in every environment and, in particular, on mobile devices where resources are limited. Kotlin has simplified the way you can write code improving your productivity with a new programming pa

Kotlin Multiplatform by Tutorials
✍ Kevin D. Moore; Carlos Mota; Saeed Taheri πŸ“‚ Library πŸ“… 2022 πŸ› Razeware LLC 🌐 English

Build native apps faster and more reliably by sharing code across Android, iOS and desktop. The best book to teach you how to share code across platforms using Kotlin Multiplatform. You’ll gain the foundation of creating user interfaces using native UI toolkits and then writing common code for se

Kotlin Coroutines by Tutorials
✍ Filip BabiΔ‡, Luka KordiΔ‡ and Nishant Srivastava πŸ“‚ Library πŸ“… 2022 πŸ› raywenderlich.com 🌐 English