isaiaholoyede / HaskellBook

My Solution to Haskell Book Exercises

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Haskell Book Solution

This documents my solution to Haskell Book Exercises.

Notes

  1. All You Need is Lambda
  2. Hello, Haskell!
  3. Strings
  4. Basic datatypes
  5. Types
  6. Type classes
  7. More functional patterns
  8. Recursion
  9. Lists
  10. Folding lists
  11. Algebraic datatypes
  12. Signaling adversity
  13. Building projects
  14. Testing
  15. Monoid, Semigroup
  16. Functor
  17. Applicative
  18. Monad
  19. Applying structure
  20. Foldable
  21. Traversable
  22. Reader
  23. State
  24. Parser combinators
  25. Composing types
  26. Monad transformers
  27. Nonstrictness
  28. Basic libraries
  29. IO
  30. When things go wrong
  31. Final project

Chapter 1: All You Need is Lambda

  1. Intermission: Equivalence Exercises
  2. Chapter 1 Exercises

Chapter 2: Hello, Haskell

  1. SayHello
  2. Exercises: Comprehension Check
  3. Exercises: Parentheses and Association
  4. Exercises: Heal The Sick
  5. Exercises: A Head Code
  6. Rewrite with Where
  7. Chapter 2 Exercises
  8. WaxOn.hs

Chapter 3: Strings

  1. Exercises: Scope
  2. Exercises: Syntax Errors
  3. PrintBroken.hs
  4. Chapter 3 Exercises
  5. Chapter 3 Exercises: Curry is Awesome
  6. Chapter 3 Exercises: Third Letter
  7. Chapter 3 Exercises: Letter Index
  8. Chapter 3 Exercises: Reverse

Chapter 4: Basic datatypes

  1. Exercises: Mood Swing
  2. Exercises: Syntax Errors
  3. Chapter 4 Exercises
  4. Chapter 4 Exercises: #8: isPalindrome
  5. Chapter 4 Exercises: #9: myAbs

Chapter 5: Types

  1. Exercises: Type Matching
  2. Exercises: Type Arguments
  3. Exercises: Parametricity
  4. Exercises: Apply Yourself
  5. Chapter 5 Exercises
  6. Chapter 5 Exercises: Determine the type
  7. Chapter 5 Exercises: Does it compile
  8. Chapter 5 Exercises: Type Signature
  9. Chapter 5 Exercises: Write The Function
  10. Chapter 5 Exercises: Sing
  11. Chapter 5 Exercises: Sing 2
  12. Chapter 5 Exercises: Arith3Broken
  13. Chapter 5 Exercises: Type-Kwon-Do

Chapter 6: Type Classes

  1. Exercises: Eq Instances
  2. Exercises: Tuple Experiment
  3. Exercises: Will They Work
  4. Chapter 6 Exercises
  5. Chapter 6 Exercises: Does It Typecheck
  6. Chapter 6 Exercises: Match The Types
  7. Chapter 6 Exercises: Type-Kwon-Do Two: Electric Typealoo

Chapter 7: More Functional Patterns

  1. Exercises: Grab Bag
  2. Exercises: Variety Pack
  3. Exercises: Case Practice
  4. Exercises: Artful Dodgy
  5. Exercises: Guard Duty
  6. Exercises: Arith 2
  7. Chapter 7 Exercises
  8. Chapter 7 Exercises: Let's Write Code
  9. Chapter 7 Exercises: Arith4 Version A
  10. Chapter 7 Exercises: Arith4 Version B
  11. Chapter 7 Exercises: Arith4 Version C

Chapter 8: Recursion

  1. Exercises: Intermission
  2. Chapter 8 Exercises
  3. Chapter 8 Exercises: Reviewing Currying
  4. Chapter 8 Exercises: Recursion
  5. Chapter 8 Exercises: Fixing DividedBy
  6. Chapter 8 Exercises: McCarthy91 Function
  7. Chapter 8 Exercises: Numbers into Words

Chapter 9: Lists

  1. Exercises: safeHead
  2. Exercise: EnumFromTo
  3. Exercise: Fearful Symmetry
  4. Exercise: PoemLines
  5. Exercise: Comprehend Thy Lists
  6. Exercise: Square Cube
  7. Exercise: Bottom Madness
  8. Exercise: More Bottoms
  9. Exercise: More Bottom - #6
  10. Exercise: Filtering
  11. Exercise: Zipping
  12. Chapter 9 Exercises: Data Char
  13. Chapter 9 Exercises: Cipher
  14. Chapter 9 Exercises: Standard Functions

Chapter 10: Folding Lists

  1. Exercises: Understanding Folds
  2. Exercises: Database Processing
  3. Exercises: Scan
  4. Chapter 10 Exercises: Warm Up
  5. Chapter 10 Exercises: Rewriting Functions

Chapter 11: Algebraic Datatypes

  1. Exercises: Dog Types
  2. Exercises: Vehicles
  3. Exercises: Cardinality
  4. Exercises: For Example
  5. Exercises: Logic Goats
  6. Exercises: Pity the Bool
  7. Record Syntax
  8. Exercises: How Does Your Garden Grow?
  9. Exercises: Programmers
  10. Exponentiation in what order?
  11. Exercises: The Quad
  12. Exercises: BinaryTree
  13. Chapter 11 Exercises
  14. Chapter 11 Exercises: Ciphers
  15. Chapter 11 Exercises: As Patterns and Language Exercise
  16. Chapter 11 Exercises: Phone Exercise
  17. Chapter 11 Exercises: Hutton's Razor

Chapter 12: Signaling Adversity

  1. Chapter 12 Exercises: Determine The Kinds
  2. Chapter 12 Exercises: Determine The Kinds
  3. Chapter 12 Exercises: String Processing
  4. Chapter 12 Exercises: Validate The Word
  5. Chapter 12 Exercises: Its Only Natural
  6. Chapter 12 Exercises: Small Library for Maybe
  7. Chapter 12 Exercises: Small Library for Either
  8. Chapter 12 Exercises: Write your own iterate and unfoldr
  9. Chapter 12 Exercises: Finally something other than a list!

Chapter 13: Building Projects

  1. Intermission: Check your understanding
  2. Chapter 13 Exercises: Hangman
  3. Chapter 13 Exercises: Cipher
  4. Chapter 13 Exercises: Palindrome
  5. Chapter 13 Exercises: Exercise 4 - ValidatePerson

Chapter 14: Testing

  1. Intermission: Short Exercise
  2. Morse Code
  3. Chapter 14 Exercises: WordNumber
  4. Chapter 14 Exercises: Using QuickCheck
  5. Chapter 14 Exercises: Failure
  6. Chapter 14 Exercises: Idempotence
  7. Chapter 14 Exercises: Make a Gen random generator for the datatype
  8. TODO: Chapter 14 Exercises: Hangman testing
  9. Chapter 14 Exercises: Validating ciphers

Chapter 15: Monoid, Semigroup

  1. Exercise: Optional Monoid
  2. Madness
  3. Exercise: Maybe Another Monoid
  4. Chapter 15 Exercises: Semigroup
  5. Chapter 15 Exercises: Validation
  6. Chapter 15 Exercises: Monoid
  7. Chapter 15 Exercises: Mem

Chapter 16: Functor

  1. Exercises: Be Kind
  2. Typecheck (fmap.fmap)
  3. ReplaceExperiment
  4. Exercises: Heavy Lifting
  5. Exercises: Instances of Func
  6. Exercises: Possibly
  7. Short Exercise
  8. Chapter 16 Exercises

Chapter 17: Applicative

  1. Exercises: Lookups
  2. Exercises: Identity Instance
  3. Exercises: Constant Instance
  4. Exercises: Fixer Upper
  5. Exercises: List Applicative
  6. Exercises: ZipList Applicative

Resources

  1. Understanding Basic Haskell Error Messages

About

My Solution to Haskell Book Exercises

License:MIT License


Languages

Language:Haskell 100.0%