We can use the keyword new
to create an instance of a class.
class Person{ String name; int age; public Person(String string, int i) { name = string; age = i; } public String getName() { return name; } } Person p = new Person("Lautturi",13); // we will get an object of Person class.Soecru:www.lautturi.com