Thanks to visit codestin.com
Credit goes to www.scribd.com

0% found this document useful (0 votes)
16 views2 pages

Practice Set I PSOOP Java 2024 25

The document outlines a list of programming problems for F.Y. B. Tech. Semester II students at Bharatiya Vidya Bhavan’s Sardar Patel Institute of Technology, focusing on encapsulation, objects, and classes in Java. It includes tasks such as creating classes for various scenarios, utilizing constructors, and implementing methods for calculations and data display. The problems aim to enhance students' understanding of object-oriented programming concepts.

Uploaded by

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

Practice Set I PSOOP Java 2024 25

The document outlines a list of programming problems for F.Y. B. Tech. Semester II students at Bharatiya Vidya Bhavan’s Sardar Patel Institute of Technology, focusing on encapsulation, objects, and classes in Java. It includes tasks such as creating classes for various scenarios, utilizing constructors, and implementing methods for calculations and data display. The problems aim to enhance students' understanding of object-oriented programming concepts.

Uploaded by

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

Bharatiya Vidya Bhavan’s

Sardar Patel Institute of Technology


(Autonomous Institute Affiliated to Mumbai University)
[Knowledge is Nectar]

ACADEMIC YEAR 2024-25

Class: F.Y. B. Tech. Semester: II Course: PSOOP(Java)

Course In charge: Nikahat Mulla


____________________________________________________________________
_______

List of Problems for practice-Set I -Encapsulation: Objects &


Classes, Constructors

1. Write a program to find the sum of the first two digit of two numbers. Use the concept of
classes and objects.
2. Create class Product. Using a method, set its values for product name, prize, brand.
Write another method to display the GST needed to pay on the current object. 3. Write a
program to design a Class cycler with name, age, no. of marathon attended
and calculate the average speed of each cycler. use appropriate data for cycler if
missing.
4. A painter is given a contract to paint a wall. He goes and measures with a meter tape.
However he makes further calculations in foot. Cost of painting per square foot is Rs. 10.
Find the amount to be paid to him for painting. A constructor is used to set the length and
breadth of the wall. Use an object as a parameter. Note: 1 meter= 3.28 feet.
5. Create a Class Student containing the student's name, marks of 5 papers of a subject
(use integer array).
Use parameterized constructors to initialize values of marks and name.
Write a method:
1. To find average of 5 papers
2. To display the name of the student, marks of 5 papers, and average.

You might also like