Download as pdf or txt
Download as pdf or txt
You are on page 1of 7

Name: Shreya Rajpoot

Enrolment number:20223254

Question 1:WAP to find the average ,sum, min, max of N numbers using user input.

Solution:

Question 2: WAP to calculate the simple interest and input by user.

Solution:
Question3: WAP to create a simple class to find out the area and perimeter of rectangle and box
using super and this keyword

Solution:
Question 4: WAP to design a String class that perform String method( Equal, reverse the string,
change case, trim etc,)

Solution:
Question 5:

you are required to maintain your own record that includes your name, father's name and date of
birth, age( computed with respect to current date). the age includes year, months and days. you are
required to show your record on the display screen such as: for displaying your name it should
display like "Name of the student: "followed by its value. display of each entity should start with new
line. use scanner class for getting the input from keyboard.

Solution:
Question 6: you are required to repeat the problem 5 with constraint that use buffer class(
bufferedReader) in place of Scanner class for taking the input from the keyboard

Solution:
Question 7: you are required to compute perimeter of a rectangle where length and breadth are
taken as float and double respectively from the keyboard. consider length and breadth as integer
while computing its perimeter and computed perimeter is displayed as double

Solution:

Question 8: get five integer number from the keyboard and check whether these numbers are prime.

Solution:
Question9: repeat the problem 9 for computing greatest common divisor(GCD) and least common
multiple(LCM) for five integers entered from keyboard) you should not use the concept of array)

Solution:

You might also like