Functional Programming Concepts
What is functional programming? Functional programming is a programming paradigm — a style of building the structure and elements of computer programs — that treats computation as the evaluation of mathematical functions and avoids changing-state and mutable data — Wikipedia
So how do we know if a function is pure or not? Here is a very strict definition of purity:
It returns the same result if given the same arguments (it is also referred as deterministic) It does not cause any observable side effects
It returns the same result if given the same arguments
immutrablility is something that cannont be changed
pure functions + immutable data = referential transparency
Node JS Tutorial for Beginners #6 - Modules and require