Academic Integrity: tutoring, explanations, and feedback — we don’t complete graded work or submit on a student’s behalf.

just the ouput for this code and like the format like from below. So it will be

ID: 3741744 • Letter: J

Question

just the ouput for this code and like the format like from below. So it will be will be easier to read them

var.1(); Green 1

var1.two(); error

1. Inheritance and Polymorphism Consider the following classes (System.out.println has beern abbreviated as s.o.pln) public class Blue extends Green ( public void one system.out-println ("Blue 1")i uper one O i public class Red extends Yellow t public void one super one Systemtout printin("Red 1") public void two System,out pzintin("Red 2") super- two) 2 public clasa Yellow extends Blue I public void two System.out-printin( Yellow 2 ) publie void three two) System.out printin("Yellow 3") publie class Green t public void one) System.out printin("Green public void three t System.out-printin("Green 3*) The following variables are defined Green varl-new Blue )1 Green var2 new Red z Blue va r 3 new Yellow ( ); object var4-new Green O

Explanation / Answer

Hi I have answered first 10 Outputs.

Please repost for others.

var1.one() ;
   Blue 1
   Green 1

var1.two();
   Error

var1.three();
   Green 3

var2.one();
   Blue 1
   Red 1

var2.two();
   Red 2
   Yellow 2

var2.three();
   Yellow 2
   Yellow 3

var3.two();
   Error

var3.three();
   Yellow 2
   Yellow 3

var4.one();
   Error