In an FP language, functions/methods should be first-class citizens.
First-class-citizen functions will enable us to use most FP paradigms if they satisfy the following rules:
- Functions/methods should be usable as function/method parameters and arguments
- Functions/methods can be returned as a result of a function/method
- Functions can take place in data structures
So far, we have seen an example implementation of all these rules.