1answer.
Ask question
Login Signup
Ask question
All categories
  • English
  • Mathematics
  • Social Studies
  • Business
  • History
  • Health
  • Geography
  • Biology
  • Physics
  • Chemistry
  • Computers and Technology
  • Arts
  • World Languages
  • Spanish
  • French
  • German
  • Advanced Placement (AP)
  • SAT
  • Medicine
  • Law
  • Engineering
bagirrra123 [75]
3 years ago
15

he superclass Student contains: a constructor that accepts a String corresponding to the name of the school the student attends

a toString method that returns 'student at X' where X is the name of the school the student attends. Write a public subclass HighSchoolStudent, based on Student, which contains: a constructor accepting a String which is used as a parameter to the superclass constructor a toString method that returns 'high school student at X'. This method must use the toString method of its superclass.
Computers and Technology
1 answer:
natita [175]3 years ago
3 0

Solution :

public $\text{class}$ Student {

$\text{protected String}$ school$;$

public $\text{Student}$(String school) {

$\text{this.school}$ = school;

}

public String $\text{toString}()$ {

return $\text{"student at"}$ + school;

}

}

HighSchool$\text{Student.java}$ :

public class $\text{HighSchoolStudent}$ extends Student {

public $\text{HighSchoolStudent}$(String school) {

super$\text{(school)}$;

}

public String $\text{toString}()$ {

return $\text{"high school"}$ + super.$\text{toString}()$;

}

}

You might be interested in
Hye I'm new branily I don't no use in this aap please follow me​
mixas84 [53]
Um ok? I think u have to have more points to be able to follow people tho
8 0
3 years ago
1. Science is the body of knowledge and methods produced by engineering.
olga nikolaevna [1]
True. Technology changes society
6 0
3 years ago
When all the input has been read, your program should produce a summary report that includes a list of all the tokens that appea
hichkok12 [17]

Answer:

I dont understand this, what is the question?

5 0
3 years ago
A lot of software loads when you boot up any computing device, such as small programs called _______________, that provide suppo
lina2011 [118]

Answer:

Services is the correct answer of the following question.

Explanation:

Loads a lot of applications when booting any computer device, including tiny programs called Services. This provides access for the various operating system functions. A service relates to research carried out by any or several individuals who support us.

  • A machine is technology that executes repetitive tasks, answers to physical activities or responds to many other software information requests.
  • The philosophy of the service explains how a supplier will understand the benefit and expected results of its products.

Other options are incorrect because they are not related to the given scenario.

8 0
3 years ago
What is cognitive overload?
kogti [31]

Answer:

C

Explanation:

C mentions the brain being overloaded

3 0
3 years ago
Read 2 more answers
Other questions:
  • When designing a website, describe 3 best practices you would give to your fellow classmate on effective web design that will ma
    9·1 answer
  • In the ____, or ad hoc, layouts configuration, there is no access point at the center of a cell.
    7·1 answer
  • The transmission control protocol (TCP) layer helps computers to communicate in which of the following ways?
    9·1 answer
  • In which step of web design is storyboarding helpful?
    14·1 answer
  • Arrange the types of movies in terms of the amount of content they can hold
    14·1 answer
  • What are the missing letters _A_TO_ ( 6 letters) a type of computer.
    13·2 answers
  • Which of the following is not a benefit provided by a stakeholder analysis document
    7·1 answer
  • I'm working on an assignment for my computer science class (Edhesive) and when I run the code, there are no errors. But when I t
    11·1 answer
  • Why do we need to learn about engineering and technology?
    6·1 answer
  • What made the digital distribution of both data and visualization more accessible to a broader audience?
    7·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!