JAVA SLIPS

Slip 1

 Q1)Write a java program to find maximum element of an Array.

Q2)Write a java program to create an abstract class Shape with methods calc_area and calc_volume. Derive two classes Sphere(radius),Box(length, breadth, height)from it. Calculate area and volume of both (use method overriding).

Q3) Java Program to create following GUI.

Slip 2

Q1)Write a Java Program to print sum of Elements of an Array.

Q2)create a table movie (movie_no,mname,release_year).Write a java program to display information about all columns in the movie table(Use ResultsetMetaData).


Slip 3

Q1)Write a java program to accept a number from command prompt and find its factorial using recursion.

Q2)Write a java program to accept 'n' integers from the user and store them in an ArrayList Collection.Display the elements of an ArrayList in Reverse order.

Q3)create a doctor table with fields doc_no, doc_name, address, city, area.write a menu driven java program to perform the following operation on Doctor Table.

1.insert

2.Delete

3.View All

4.Exit


Slip 4

Q1)Write a java program to accept a number from user and find its sum of digits.

Q2)Define a class person(pid,pname,gender,age).create n objects of person class using parametrized constructor and display using toString() method.

Q3)Java program to accept value from user and print it in Matrix format.

Comments