Exam Details

Subject java programming
Paper
Exam / Course m.c.a.science
Department
Organization solapur university
Position
Exam Date 20, April, 2017
City, State maharashtra, solapur


Question Paper

M.C.A. (Science) (Semester III) (CBCS) Examination, 2017
JAVA PROGRAMMING
Day Date: Thursday, 20-04-2017 Max. Marks: 70
Time: 02.30 PM to 05.00 PM
Instructions: Question No. 1 and 2 are compulsory
Attempt any 3 questions from Q.No.3 to Q.No.7
Figures to the right indicate full marks.
Q.1 Choose correct alternatives 10
Which one of these lists contains only Java programming
language keywords?
class, if, void, long, Int, continues
goto, instanceof, native, finally, default, throws
try, virtual, throw, final, volatile, transient v
strictfp, constant, super, implements, do
Which will legally declare, construct, and initialize an array?
int myList
int myList
int myList
int myList
What will be the output of the program?
Public void test(int

int odd
if(odd) Line 4

Sytem.out.println("odd");

else

System.out.println("even");


Which statement is true?
Compilation fails.
"odd" will always be output.
"even" will always be output.
"odd" will be output for odd values of and "even" for even
values.
Page 2 of 4
What will be the output of the program?
int i j 10;
do

If(i

break;


while
System.out.println("i " " and j "
i 6 and j 5 i 5 and j 5
i 6 and j 4 I 5 and j 6
What will be the output of the program
public class Aclass

void Aclass()

System.out.println("Class

Public static void main(String[] args)

new Aclass();


Class A
Compilation fails.
An exception is thrown at line 3.
The code executes with no output.
Which of the following is/are legal method declarations?
Protected abstract void
Static final void
Synchronized public final void m1
Private native void
1 and 3
2 and 4
1 only
All of them are legal declarations.
Which one creates an instance of an array?
int ia new
float fa new float[20];
char[ ca "Some String";
int ia[
Page 3 of 4
Which is a valid declaration within an interface?
public static short stop 23;
protected short stop 23;
transient short stop 23;
final void madness(short stop);
What will be the output of the program?
public class x

public static void main(String args)

try

badMethod();
System.out.print("A");

catch (Exception ex)

System.ot.print("B");

finally

System.out.print("C");

System.out.print("D");

public static void badMethod()

AC BC ACDS ABCD
10) Which cannot directly cause a thread to stop executing?
Calling the SetPriority() method on an Thread object.
Calling the wait() method on an object.
Calling notify() method on an object.
Calling read() method on an InputStream object
Write whether true or false. 04
Can we compare int variable with a boolean variable?
The method toLowerCase( changes all lowercase letters to
uppercase and all uppercase letter to lowercase.
The method indexOf(",") will allow you to search for the
location of a comma.
All variable must be declared before they can be used.
Q.2 Write short notes on the following 08
Method Overriding
ii) Thread Priority
Page 4 of 4
Answer the following 06
Explain with suitable example, how to use a try-catch block,
Explain with example.
ii) Explain steps in creation and implementation of package with
example.
Q.3 Answer the following 14
Explain inter-thread communication with example
WAP to read number from used and print Fibonacci Series up to
that numbers. If given number is less than 2 then throw
exception and give message "Enter number greater than two".
Q.4 Answer the following 09
Explain how to draw following shape in applet
1. Ellipse
2. Arcs
3. Polygon
Explain Applet Life cycle with example 05
Q.5 Answer the following
Explain with suitable example how to extend exception. 07
State the feature of Gride Layout and explain how to implement
it.
07
Q.6 Answer the following
State the purpose of the following JDBC classes an interfaces 08
i. Driver manager
ii. Connection
iii. Statement
iv. Result set
State the feature of Flow Layout and explain how to implement it 06
Q.7 Answer the following
Explain any MouseMotionListener methods with example and
how to check which mouse button is pressed by using
MouseEvent class
07
What is difference between String and String buffer and explain
3 methods of String and String buffer class with example.


Subjects

  • .net
  • artificial intelligence
  • computer communication network
  • computer graphics
  • computer oriented statistics
  • data mining and warehouse
  • data structures
  • database management system
  • digital circuits and microprocessors
  • digital image processing
  • discrete mathematical structures
  • distributed operating system
  • finite automata
  • introduction to computers
  • java programming
  • management
  • mobile computing
  • network security
  • numerical analysis
  • object oriented programming using c++
  • opeartions research
  • operating system
  • pattern recognition mobile computing
  • programming using - c
  • programming with php
  • software engineering
  • system software
  • uml
  • web design techniques
  • web technology