why do we check whether driver object has already exists code example
Example: why do we check whether driver object has already exists
(if driver==null)
This is because of singleton pattern.
It will not create object of the class
again if already initialized once.