Inheritance involves the concept of super class parent


1. There are many different concepts associated with OOP (Object-oriented programming) like:

• Class
• Object
• Inheritance
• Polymorphism
• Abstraction
• Encapsulation
• Interface
• Method Overloading
• Method Overriding
• ...and others

QUESTION: Pick FIVE of the above listed OOP concepts and describe each in details

2. (2) In Java (and OOP), Inheritance involves the concept of super class (parent class) and sub class (derived class). What is a super class in Java? What is a sub or derived class in Java?

(3) 3. Code a simple class in JAVA classed "Student." Your class must contain the followings:

• Variables (name, age, addressStreet, city, state, zip, country)
• Setter and Getter methods

Example:
public void setName(String name) {
this.name = name;
}

public String getName() {
return name;
}

4. Code a short JAVA program that demonstrates Inheritance.

HINT:

• To demonstrate true OOP inheritance, your code must include a super (parent) class and a sub class (derived class)
• As an example, class Student could be a super class while class GraduateStudent is a sub class that inherits from Student class.
• In your subclass (i.e. GraduateStudent), you must include the JAVA inheritance keyword that shows that a class inherits from another.

Solution Preview :

Prepared by a verified Expert
JAVA Programming: Inheritance involves the concept of super class parent
Reference No:- TGS0761486

Now Priced at $40 (50% Discount)

Recommended (94%)

Rated (4.6/5)