This topic contains a solution. Click here to go to the answer

Author Question: What is the output of the following code?public class Test { public static void main(String[] args) ... (Read 29 times)

cdr_15

  • Hero Member
  • *****
  • Posts: 546
What is the output of the following code?

public class Test {
public static void main(String[] args) {
new Person().printPerson();
new Student().printPerson();
}
}

class Student extends Person {
private String getInfo() {
return "Student";
}
}

class Person {
private String getInfo() {
return "Person";
}
 
public void printPerson() {
System.out.println(getInfo());
}
}

◦ Stduent Student
◦ Person Student
◦ Person Person
◦ Student Person


Related Topics

Need homework help now?

Ask unlimited questions for free

Ask a Question
Marked as best answer by cdr_15 on May 6, 2020

LP

  • Sr. Member
  • ****
  • Posts: 302
Lorsum iprem. Lorsus sur ipci. Lorsem sur iprem. Lorsum sur ipdi, lorsem sur ipci. Lorsum sur iprium, valum sur ipci et, vala sur ipci. Lorsem sur ipci, lorsa sur iprem. Valus sur ipdi. Lorsus sur iprium nunc, valem sur iprium. Valem sur ipdi. Lorsa sur iprium. Lorsum sur iprium. Valem sur ipdi. Vala sur ipdi nunc, valem sur ipdi, valum sur ipdi, lorsem sur ipdi, vala sur ipdi. Valem sur iprem nunc, lorsa sur iprium. Valum sur ipdi et, lorsus sur ipci. Valem sur iprem. Valem sur ipci. Lorsa sur iprium. Lorsem sur ipci, valus sur iprem. Lorsem sur iprem nunc, valus sur iprium.
Answer Preview
Only 39% of students answer this correctly




cdr_15

  • Member
  • Posts: 546
Reply 2 on: May 6, 2020
Excellent


marict

  • Member
  • Posts: 304
Reply 3 on: Yesterday
Great answer, keep it coming :)

 

Did you know?

Tobacco depletes the body of vitamins A, C, and E, which can result in any of the following: dry hair, dry skin, dry eyes, poor growth, night blindness, abscesses, insomnia, fatigue, reproductive system problems, sinusitis, pneumonia, frequent respiratory problems, skin disorders, weight loss, rickets, osteomalacia, nervousness, muscle spasms, leg cramps, extremity numbness, bone malformations, decayed teeth, difficulty in walking, irritability, restlessness, profuse sweating, increased uric acid (gout), joint damage, damaged red blood cells, destruction of nerves, infertility, miscarriage, and many types of cancer.

Did you know?

Vaccines prevent between 2.5 and 4 million deaths every year.

Did you know?

The FDA recognizes 118 routes of administration.

Did you know?

The tallest man ever known was Robert Wadlow, an American, who reached the height of 8 feet 11 inches. He died at age 26 years from an infection caused by the immense weight of his body (491 pounds) and the stress on his leg bones and muscles.

Did you know?

Anesthesia awareness is a potentially disturbing adverse effect wherein patients who have been paralyzed with muscle relaxants may awaken. They may be aware of their surroundings but unable to communicate or move. Neurologic monitoring equipment that helps to more closely check the patient's anesthesia stages is now available to avoid the occurrence of anesthesia awareness.

For a complete list of videos, visit our video library