Question: Java code. How to successfully run the following code without modifying the content of the following code, i have person,student class. They are very similar
Java code. How to successfully run the following code without modifying the content of the following code, i have person,student class. They are very similar , but have different parameters, such as the school class and the student number.The red line reports that the person class cannot be converted to a student class.

Person bob-new Person (11315, "Bob) int bobAcc1d = b. openAccount (bob, 1000) ; Persan aliceneStudent 12512AliceNCan1234 int aliceAcctId - b. openAccount (alice, 500) Person rich = new Person (51542, "Rich P. Person); int richAcctId-b. openAccount (rich, 1000000) Person richStudent = new Student (23814 Rich P. Student int richStudentAcctId - b. openAccount (richStudent, 100100)
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
