Zusammenfassung der Ressource
Haskell - Higher order functions
- Are functions that can take functions as parameters and return functions as return values
- Curried functions
- Recursion
- The function in Haskell officially only takes one parameter
- Functional programming uses higher order functions to abstract away common patterns
- Maps
- Filters
- Equivalent of applying several predicates in a list comprehension is either filtering something several times
- Lambdas
- Are anonymous functions that are used because we need some functions only once
- Lambdas are expressions
- Also can match with patterns
- Normally surrounded by parentheses
- Folds
- They reduce the list to some single value
- Binary function
- Starting value
- Can be used to implement any function where you traverse a list once
- Sacns
- Scans are used to monitor the progression of a function that can be implemented as a fold
- Function application
- Function composition