JAVA ASSIGNMENT 2: SUBMIT BEFORE 05/11/2025
SUBMIT YOUR WORK AS A PDF FILE
1. Write a java program that implements the following concepts, indicate with a comment
in your code how you have implemented the concepts:
i. Classes
ii. Objects
iii. Inheritance
iv. Polymorphism
v. Encapsulation
vi. Abstraction
2. In Java, polymorphism can be of three types:
i. Function Overloading: Function overloading is using a single function name to
perform different types of tasks.
ii. Function Overriding: Function overriding is changing the behavior of a function that
is derived from the base class using inheritance.
Provide an example of a java program for each case
3. Demonstrate multidimensional array
4. Demonstrate how constructors can take parameters and use them to initialize
attributes.