[go: up one dir, main page]

0% found this document useful (0 votes)
97 views5 pages

Practical List - OOPJ - Sem4 - IT - LDCE

This document outlines a laboratory plan for a semester-long course on Object Oriented Programming - I. It includes 12 labs to be completed over the semester. The labs cover core concepts like creating classes with methods and variables, inheritance, interfaces, exception handling, file I/O, and multithreading. Example programs include classes for products, bank accounts, students and related subclasses. Later labs involve creating packages, menu-driven programs, and saving object data to files. The goal is for students to gain hands-on experience with key OOP concepts.

Uploaded by

Jatin Parmar
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
97 views5 pages

Practical List - OOPJ - Sem4 - IT - LDCE

This document outlines a laboratory plan for a semester-long course on Object Oriented Programming - I. It includes 12 labs to be completed over the semester. The labs cover core concepts like creating classes with methods and variables, inheritance, interfaces, exception handling, file I/O, and multithreading. Example programs include classes for products, bank accounts, students and related subclasses. Later labs involve creating packages, menu-driven programs, and saving object data to files. The goal is for students to gain hands-on experience with key OOP concepts.

Uploaded by

Jatin Parmar
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 5

Object Oriented Programming -I (3140705)

B.E SEMESTER - IV 2022– 2023

L. D. COLLEGE OF ENGINEERING
INFORMATIONTECHNOLOGY DEPARTMENT
AHMEDABAD
LABORATORY PLANNING
Dept: Information Technology SEMESTER: BE-IV TERM: 2022-23
SUBJECT: -OBJECT ORIENTED PROGRAMMING - I ( 3140705) Div: A,B,C

Faculty: Dr. Purvi Ramanuj

No AIM CO
1 I. Write a Program that displays Welcome to Java, Learning CO1(not
Java Now and Programming is fun. considered
II. Write a Java Program to calculate simple interest. in
III. Write a Java Program to check Leap Year.\ evaluation)
IV. Write a Java Program to add two binary numbers.
2 I. Write a Java Program to check if a number is Armstrong CO1(not
from given array. considered
II. Write a Java Program to perform bubble sort on Strings. in
III. Write a Java program to perform different methods of evaluation)
string buffer class.
3 I. Create a class named Product with instance variables MRP CO2(not
and QUANTITY and methods display (), setdata (). In considered
display () method, display the instance variables value (MRP in
and QUANTITY). And in setdata () method set the instance evaluation)
variable values (MRP and QUANTITY)).
II. Create a class named Account with instance variables
Ac_No,Name and Balance and methods display (), setdata
(),deposit(). In display () method, display the instance
variables value (Ac_No,Name and Balance). And in setdata ()
method set the instance variable values (Ac_No,Name and
Balance) and in deposit() method the amount that user wants
to deposit that will be deposited.
III. Create a class named Student with static variable Enrollment
no. and instance variable Name and methods display (),
setdata (). in display () method, display the variables value
(Enrollment no. and Name). And in setdata () method set the
variable values (Enrollment no. and Name).

4 I. Create a default constructor of class Product to print- CO2


“Welcome to Super-Market.” And parameterized constructor
to get the values of variables. (using Command Line
Arguments)
II. Create a default constructor of class Account to print-
“Welcome to Bank.” And parameterized constructor to get the
values of variables. (Using Command Line Argument).
III. Create a default constructor of class Student to print-
“Welcome to Student-Information system.” And
parameterized constructor to get the values of variables
(Enrollment no. and Name). (using Command Line
Arguments)
5 I. Create three inherited classes named-Crockery, Household, CO2
Food-items from Product super class and inherit the
instance method(display () and setdata ()) and variables(MRP
and QUANTITY) of super class Product
II. Create two inherited classes named-Savings,Current from
Account super class and inherit the instance method(display
(),setdata () and deposit()) and variables(Ac_No,Name and
Balance) of super class Account.
III. Create two inherited classes named-BE,ME from Student
super class and inherit the instance method(display () and
setdata ()) and variables(Enrollment no and Name) of super
class Student and make an instance variable Entry_year and
final variable duration for each of the above class

6 I. Create a interface named place with method search() and CO4


variable BlockNo and implement it together on all the above
classes. Use binary I/O.
II. Create an interface named Branch with method search() and
variable IFSC Code and implement it together on all the
above classes.
III. Create a interface named Result with method getMarks() and
variable percentage and implement it together on all the above
classes. in getMarks() get the marks of 3 subjects and
calculate the average inside the method.
7 I. Define three objects for all the classes named- Crockery, CO4
Household, Food-items and store the initial values for all the
objects in arraylist or collection.
Example: Class Crockery extends Product, implements place;
Define objects of crockery-plates,cups,jug;
II. Define three objects for all the classes named-
Savings,Current and store the initial values for all the objects
in arraylist or collection.
Example: Class Savings extends Account implements Branch;
Define objects.
III. Define two objects for all the classes named- BE,ME and
store the initial values for all the objects in arraylist or
collection.
Example: Class BE extends Student, implements Result;
Define objects of BE.

8 I. Create a Package and put all the classes mentioned above CO4
in package.
II. Create a Package and put all the classes mentioned above
in package.
III. Create a Package and put all the classes mentioned above
in package.
9 I. Create a method named buy () in the main function CO3
performing exception handling.
Example: Banana = 10; Banana_Buy = 12
Here, Banana_Buy > Banana (throw exception).
II. Create a method named Withdraw () in the main function
performing exception handling.
Example: Balance = 1000; Withdraw = 12000
Here, Balance<Withdraw (throw exception)
III. Create a method named searchStudent() in the main ()
Function performing exception handling.
Example: if we search the student name and if it is present in
the list then it will represent the details else it will throw an
exception.

10 I. Save object data in the file using File Writer class, using CO4
parameterized constructor.
II. Save object data in the file using File Writer class, using
parameterized constructor.
III. Save object data in the file using File Writer class, using
parameterized constructor.

11 I. Create customer class which extends thread class and CO3


contains two instance variables name, ProductName and static
variable Product Quantity. For example if two customers are
trying to buy the same product at once then follow
synchronization of two customers extending thread class.
II. Create Customer class which extends thread class and
contains two instance variables name, BankName and static
variable Product Balance. if two customers are trying to
Withdraw from the same Account at once then then follow
synchronization of two customers extending thread class.
III. Create Number class which extends thread class and create
two objects a1, a2 displaying the number having even
Enrollment no. and odd Enrollment no.
12 I. Create the above system using a menu and implement it using CO4
switch statement. For example, in the above system
implement the menu driven like..
1. For setting a value of MRP and QUANTITY for the
product.
2. For buying a product.
3. For searching a product.
4. To delete a product from storage.
5. To show stored object data
II. Create the above system using a menu and implement it using
switch statement. For example, in the above system
implement the menu driven like.
1. For Setting a value of Ac_No,Name and Balance for the
Bank
2. For Withdraw from a Account.
3. For Searching a Account.
4. To delete an Account from Bank.
5. To show stored object data
III. Create the above system using a menu and implement it using
switch statement. For example, in the above system
implement the menu driven like..
1. Add Student details.
2. Update student Details.
3. For Searching a Student.
4. Delete Student Details.
13 Create the above system user interface of menu using CO5
JAVAFX

Rubrics for practical:


Program (Excellent)(4) (Good)(3) (Fair)(2) (Beginning)(1)
Program execution Program executes Program executes Program executes Program does not
correctly with no with a minor error with multiple execute (0-1)
syntax or runtime minor (easily fixed
errors error)
Design of output Program displays Program displays Program does not Output is poorly
more than minimally display the designed (0-1)
expected expected output required output
Design of logic Program is Program has slight Program has Program is
logically well logic errors that do significant logic incorrect (0-1)
designed no significantly errors
affect the results
Standards Program is Few inappropriate Several Program is poorly
stylistically well design choices (i.e. inappropriate written (0-1)
designed poor variable design choices (i.e.
names, improper poor variable
indentation) names, improper
indentation)
Documentation Program is well Missing one Missing two or Most or all
documented required comment more required documentation
comments missing (0-1)

You might also like