Discuss the difference between procedural programming and functional programming
There are several differences in Procedural and Functional programming.
Procedural:
Functional:
Procedural:
- The output of a routine does not always have a direct correlation with the input.
- Everything is done in specific order.
- Execution of a routine may have side effects.
- Tends to emphasize implementing solutions in a linear fashion.
Functional:
- The output routine often recursive.
- Always return the same output for given input.
- Order of evaluation is usually undefined.
- There are no operation have side effects.
- Good fit for parallel execution.
Comments
Post a Comment