You are on page 1of 1

Test - JAVA (SET 4)

Time : 60 min
Please make a zip file containing files and answers . FIle names should be there questions number.
And email them at cmpundhir@gmail.com.

Q. 1 Write a Java Program to print the elements of an array.


Q. 2 Write a java program to sort an array elements using bubble sort algorithm.
Q. 3 Write a java program to find 3rd largest number in an array.
Test case :
Input: 1,2,5,6,3,2,4,1

Output: 4

Q. 4 Write a program to print a Square matrix .


Test case 1 :
Input : 2
Output :
1 2
3 4

Test case 2 :
Input : 3
Output :
1 2 3
4 5 6
7 8 9
Q. 5 Write a Java program to print the following pattern on the console using loops.
12344321
123**321
12****21
1******1

Q. 6 Write a Java program to print the following pattern


1
24
369
4 8 12 16
5 10 15 20 25
6 12 18 24 30 36
7 14 21 28 35 42 49
8 16 24 32 40 48 56 64
9 18 27 36 45 54 63 72 81
10 20 30 40 50 60 70 80 90 100

cmpundhir@gmail.com
8745095350 Page 1

You might also like