I keep coming across code where people instantiate a new ArrayList and assign it to the List interface, like this:
List names = new ArrayList&l
To decouple your code from a specific implementation of the interface.
This also helps you to move to another implementation of the List interface in the future.
For example -
You have List later on you decide that you should have used some other implementation of the List interface, say LinkedList so you would just change it to List and nothing breaks.