Assignment Unit III
Assignment Unit III
Program: CO4I
Course : Java Programming (JPR) (22412)
Unit-III:Inhertance, Inteface and Package
Course Outcome(COa): Apply concept of inheritance for code reusability
Unit Outcomes(UO):
U3-3a: Apply the type of identified inheritance fpor the given programming problem Apply
U3-3b: Defferentiate between overloading and overriding for the given example Understand Apply
U3-3c: Develop programs using the specified interface Apply
U3-3d Create user defined package for the given problem Apply
U3-3e: Add class and interface to the given package Apply
9 What is final variable and method? How is it different from abstract method?
16 List any four built in packages from Java API along with their use.
19 What is package? State how to create and access user defined package in Java.
Write a program to create a package Math_s having two classes addition and subtraction.
20 Use suitable methods in each class to perform basic operations.
Create a class “Rectangle‟ that contains “length‟ and “width‟ as data members. From this
class drive class box which has additional data member ”depth‟. Class “Rectangle‟
22 consists of a constructor and an area ( ) function. The derived “Box‟ class have a
constructor and override function named area ( ) which returns surface area of “Box‟ and a
volume ( ) function. Write a java program calling all the member function.
23
24
Remember UO -3b
Remember UO -3b
Remember,
Apply
UO -3b
Remember UO -3b
Remember UO - 3c
Understand UO - 3c
Remember UO - 3c
Understand,
Apply
UO -3e
Remember UO -3d
Remember UO -3d
Understand,
Apply
UO-3a
Remember UO-3e
Remember UO-3e
Understand UO-3c
Apply UO-3e
Apply UO-3b
Remember,
Understand
Apply UO-3d
Apply UO-3d
Apply UO-3d