...

/

Advantages and Disadvantages of Functional Programming

Advantages and Disadvantages of Functional Programming

Learn about the advantages and disadvantages of functional programming in this lesson.

Advantages of functional programming

Here are the main advantages of functional programming:

FP often creates less code

This is because it tends to work at a slightly higher level than the other paradigms, so it achieves more with each line of code.

Intent of the code is clearer

For example, if you use map to apply a function to a data stream, the meaning is clear and unambiguous. However, if you define a procedural function that loops over the data and applies the function, you need to read and ...