Imperative vs Declarative
Imperative:
It is a code that says the machine, what to do and how to do.
Declarative:
It is a code that says the machine, what to do and what should happen. It doesn't tell how to do. Ex: Humans
Functional programming is mostly be a declarative, we don't say how to do.
Last updated