Imperative and declarative approach
For example, you are going for Tom’s home and in imperative method, this is how you choose the path and direction (go right, or left etc)
So, what to do and how to do is important in this approach.
In declarative ...