Question: SECTION - A 1. Write a program in Java using Bluej that performs the following tasks: i. Creates a class called Professors having protected fields


SECTION - A 1. Write a program in Java using Bluej that performs the following tasks: i. Creates a class called Professors having protected fields profName, proflD, profMobleNo and a class variable universityName to store the name of the university. ii. Write the constructors for Professors class to initialize all the attributes(fields). iii. Write a method displaydetails() in Professors to print all attributes of the object. iv. Create an object of Professors class and call displayDetails[). 2. Write a program in Java using i. Creates an abstract class bluej that performs the following tasks: that displays the fields. ii. Add an abstract method called area( in the class Polygons which returns a double value. iii. Creates a subclass called Rectangle of the Pollygons class. iv. Write the constructor for Rectangle class to set the fields sidel and side2; v. Implement the area() method in the subclass Rectangle to find the area of rectangle. vi. Create object of Ractangle and call displayO and areaO methods
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
