Graduation Level: Diploma of Engineering
Course: Computer Engineering
Subject Name: Object Oriented Programming using JAVA
Subject Code: 2102CS304
Semester: 3
Suggested List of Experiments / Exercises:
Ex. No. Unit No. Practical / Exercise
1 2 Write programs in Java to Create class Student with datamember name and
(Class,Object rollno and assign value of that datamember and display data.
and Method Write a program to print the area of a rectangle by creating a class named
Overloading) 'Area' having two methods. First method named as 'setDim' takes length and
breadth of rectangle as parameters and the second method named as
'getArea' returns the area of the rectangle. Length and breadth of rectangle
are entered through keyboard.
Write a program to Assign and print the roll number, phone number and
address of two students having names "ABC" and "XYZ" respectively by
creating two objects of class 'Student'.
Write a program to Print the average of three numbers entered by user by
creating a class named 'Average' having a method to calculate and print the
average.
Write a program to create class bank account having data members as
accountno and salary, create a method getvalue to get value and setvalue to
diplay data, create two object of class.
Write a program to calculate the Power of a Number using class object and
method
Write a program to using class Person to display name and age with method
WAP using class Cube and calculate area using method with parameter
Create a class named 'PrintNumber' to print various numbers of different
datatypes by creating different methods with the same name 'printn' having a
parameter for each datatype.