Simple Java Program using constructors. Here the constructor is “Cars”. //constructors public class Cars { public Cars(String name) { System.out.println("super "+name); } public static void main(String []args) { Cars bmw=new Cars("cars"); } } Click here for instructions for executing the program.
Vajahath Ahmed's personal blog.