Functional Programming
- In computer program, a functional programming treats every computation as an evaluation of mathematical functions and never use mutable data to change it's state.
- The output value of a pure function depends on the arguments which are input to the function and will produce the same result every time for the same set of inputs.
- It means f(x) will always produce the same result y for same value of x.
- A function is full of functions or declarations instead of statements.
- Languages: Scala, Python, Erlang, Haskell etc.
Various concepts of functional programming :
- Higher Order Functions
- First Class Function
- Pure Function
- Immutability
Comments
Post a Comment