Explain how to create instance of a class by giving an example.
Java supports 3 ways of creating instances.
By using new operator
Ex : Product prodMouse = new Product();
By using Class.forName(classname).newInstance() method
Ex: Class.forName(Product).newInstance();
By using clone() method
Ex: Object copy = obj.clone();