Programing Paradigms Complexity
work in progressLevels of Difficulty
Is functional programing more difficult than procedural programing?
Yes.
Is object oriented programing more difficult than procedural programing?
Yes.
Is modular programing more difficult than line orderd instruction with goto line?
Yes.
Line based programing, modular programing, object oriented programing, functional programing

- The diagram is the programing language BASIC, universal lang in 70 and 80s.
- This is most easy to code.
- Next level is modular programing. i.e. you write procedures to structure the code instead of sequence of line numbers . This is more difficult to code.
- next level is OOP (object oriented programing) and FP (functional programing).
- OOP means you write nested procedures that box data and its relevant procedures.
- FP means you write procedures that does not use global variables.
- Both, are more difficult to code than just modular programing or BASIC.
- We use them because when code becomes complex, they are much easier to manage.
- But there is a cost. They are more difficult to write initially.
- In OOP, you need to think about class hierarchy, grouping of functions, static variable, static functions (methods), iterators.
- In FP, you need to use map, recursion, sequence function calls, function taking function or returning function to avoid updating global variables.