0% found this document useful (0 votes)
212 views3 pages

3 Hours / 70 Marks: Seat No

This document contains instructions and questions for a Java programming exam. It is divided into 6 sections with a total of 70 marks. The instructions specify that all questions are compulsory and to answer each question on a new page. Diagrams should be included where necessary. The document contains questions related to Java concepts like operators, functions, interfaces, packages, files, exceptions, loops, arrays, inheritance, threads, packages and more. It also includes questions asking to write Java programs to perform tasks like copying files, sorting arrays, displaying output, and more.

Uploaded by

Hemant Thawani
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)
212 views3 pages

3 Hours / 70 Marks: Seat No

This document contains instructions and questions for a Java programming exam. It is divided into 6 sections with a total of 70 marks. The instructions specify that all questions are compulsory and to answer each question on a new page. Diagrams should be included where necessary. The document contains questions related to Java concepts like operators, functions, interfaces, packages, files, exceptions, loops, arrays, inheritance, threads, packages and more. It also includes questions asking to write Java programs to perform tasks like copying files, sorting arrays, displaying output, and more.

Uploaded by

Hemant Thawani
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/ 3

22412

21222
3 Hours / 70 Marks Seat No.
15 minutes extra for each hour

  Instructions – (1) All Questions are Compulsory.


(2) Answer each next main Question on a new page.
(3) Illustrate your answers with neat sketches wherever
necessary.
(4) Figures to the right indicate full marks.
(5) Assume suitable data, if necessary.
(6) Mobile Phone, Pager and any other Electronic
Communication devices are not permissible in
Examination Hall.
Marks

1. Attempt any FIVE of the following: 10


a) Enlist the logical operators in Java.
b) Give the syntax and example for the following functions
i) min ( )
ii) Sqrt ( )
c) Define the interface in Java.
d) Enlist any four inbuilt packages in Java.
e) Explain any two methods of File Class.
f) Write syntax of elipse.
g) Enlist any four compile time errors.

P.T.O.
22412 [2]
Marks
2. Attempt any THREE of the following: 12
a) Explain any four features of Java.
b) Write a Java program to copy the content of one file into
another.
c) Write the difference between vectors and arrays. (any four
points)
d) Explain exception handling mechanism. w.r.t. try, catch, throw
and finally.

3. Attempt any THREE of the following: 12


a) Write a Java program to find out the even numbers from
1 to 100 using for loop.
b) Explain any four visibility controls in Java.
c) Explain single and multilevel inheritance with proper example.
d) Write a java applet to display the following output in Red
color. Refer Fig No. 1.

Fig No. 1.

4. Attempt any THREE of the following: 12


a) Explain switch case and conditional operator in java with
suitable example.
b) Draw and explain life cycle of Thread.
c) Write a java program to sort an 1-d array in ascending order
using bubble-sort.
d) Explain how to create a package and how to import it.
e) Explain
i) drawLine
ii) drawOval
iii) drawRect
iv) drawArc
22412 [3]
Marks
5. Attempt any TWO of the following: 12
a) How to create user defined package in Java. Explain with
an suitable example.
b) Write a Java program in which thread A will display the
even numbers between 1 to 50 and thread B will display
the odd numbers between 1 to 50. After 3 iterations thread
A should go to sleep for 500 ms.
c) What is constructor? List types of constructor. Explain
paramaterized constructor with suitable example.

6. Attempt any TWO of the following: 12


a) Write a Java program to count the number of words from a
text file using stream classes.
b) Explain the difference between string class and string buffer
class.
Explain any four methods of string class.
c) Write a Java applet to draw a bar chart for the following
values.
Year 2011 2012 2013 2014
Turnover
110 120 170 160
(Rs. crores)

You might also like