Question: Add an overload constructor to the program below. Instantiate an objectthat uses that overloaded constructor in the main method. public class Student { private String
Add an overload constructor to the program below. Instantiate an objectthat uses that overloaded constructor in the main method. public class Student { private String name; private int age; public Student() { name = "No name yet."; age = 0; } public Student(String name, int age) { this.name = name; this.age = age; } }
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
