- The function’s output depends only on its input variables.
- It doesn’t mutate any hidden state.
- It doesn’t have any “back doors”: It doesn’t read data from the outside world (including the console, web services, databases, files, etc.), or write data to the outside world.
- As a result of this definition, any time you call a pure function with the same input value(s), you’ll always get the same result.
Pure function → belongs to → Functions.