GoConqr hat ein neues Design! Sag uns, wie es dir gefällt.

Mindmap

Higher-Order Functions

Daniel Almanza Ingeniería Spanisch

Inhalt der Mindmap

Higher-Order Functions

  1. Three Possibilities

    • Take functions as parameters
    • Return functions as parameters
    • Both
  2. Curried Functions

    • By applying a space between two things
    • Space considered as an operator
      • Separated by arrows ->
    • Partially Applied Functions
      • Take the parameters you need
    • Infix functions
      • Parentheses plus parameter
  3. Associations and Filters

    • The function is taken and applied to each element
    • Something new is produced
    • Predicates
      • If it is true, it is included
    • Map and Filter
      • One time only
        • It is trimmed according to need
      • Lists by Compression
  4. Lambdas

    • Anonymous function
      • It is only needed once
      • To pass it to higher order function
    • The sign \
      • Parameters separated by space
        • It is created: \ ... -> (...)
    • Expressions
      • They take any number of parameters
  5. Folds

    • Reduce lists to a single value
      • Binary calls Accumulator
        • So on
        • It can be of any type
    • Take a binary function
      • An Initial Value or Accumulator
        • List to fold
    • To the left
      • Finite
    • To the right
      • Infinite
  6. $ Function

    • Order of low precedence
    • Associative on the right
    • Replace Parenthesis
  7. Composition of Functions

    • They must have the same type of parameter
    • Point Free Style
      • Pass values easily

Informationen

Beschreibung
Ingeniería Mindmap am Higher-Order Functions, erstellt von Daniel Almanza am 19/02/2018.
Erstellt von
Daniel Almanza
Aufrufe
0
Bewertung

Mehr zu Functional Programming and Haskell

Feedback

Worum geht es?

Wie gefällt dir das neue Design?

Dein Eindruck