For the code below: public class College extends Student { public static void main(String[ ] args) { new College( ); } public College ( ) { this(“First semester"); System.out.println( "Third year" );...


For the code below:


public class College extends Student {


public static void main(String[ ] args)


{ new College( ); }


public College ( )


{ this(“First semester");


System.out.println( "Third year" ); }


public College (string G ) { System.out.println(G); } }


class Student extends S_info {


public Student ( )


{ System.out.println("Student No. 123"); }


public Student (String S)


{ System.out.println(S); } }


 class S_info{ public S_info ( )


{ System.out.println("student age: 21"); } }


1- Draw the diagram for the constructor chaining.


2- Put the values for the strings G and S.


3- Trace the output for the entire code.



Jun 03, 2022
SOLUTION.PDF

Get Answer To This Question

Related Questions & Answers

More Questions »

Submit New Assignment

Copy and Paste Your Assignment Here