You are on page 1of 9

[1] Which of the following is NOT one of the programming techniques.

Choice a
Structured programming
Choice b
Modular programming
Choice c
Bottom-up programming
Choice d
*******
Destructred programming
[2]

In OOP approach programs are divided into

Choice a
Objects

*********

Choice b
Methods
Choice c
Functions
Choice d
Procedures

[3] In OOP, the concept of insulating data and from direct access by the program is
known as
Choice a
Data hiding
Choice b
Inheritance
Choice c
Polymorphism
Choice d
Abstraction

**********

[4] Which of the following is NOT True with respect to OOP


Choice a
Upgrading systems is difficult
Choice b
********
Multiple objects co-exists without any interference
Choice c
Secure Programs can be built

Choice d
Software development is made easy

[5]

Dynamic binding is associated with

Choice a
Polymorphism
Choice b
Inheritance
Choice c
*********
Both Option1 and Option2
Choice d
Neither Option1 and Option2
[6] In OOP process by which objects of one class acquire the properties of objects
of another class is
Choice a
*********
Inheritance
Choice b
Polymorphism
Choice c
Encapsulation
Choice d
Abstraction

[7] In OOP the concept of representing essential features without including the
background details is called as
Choice a
Data Hiding
Choice b
************
Data Abstraction
Choice c
Inheritance
Choice d
Dynamic Binding

[8] In OOP, the concept of Inheritance provides us with


Choice a
Insulation

Choice b
Linking
Choice c
Reusability

***********

Choice d
Sharing
[9]

In OOP approach programs are divided into

Choice a
Objects

**********

Choice b
Methods
Choice c
Functions
Choice d
Procedures
10] What are user define data types and behave like built-in types of a
programming language.
Choice a
Objects
Choice b
Methods
Choice c
Templates
Choice d
Classes
[11]

***********

What does message passing involve in OOP

Choice a
It involves specifying name of the object
Choice b
It involves name of the method
Choice c
It involves the information to be sent
Choice d
***********
All of the options 1,2,3

[12] OOP treats what as a critical element in program development and does not allow
it to flow freely around the system.
Choice a
Procedures
Choice b
Action
Choice c
Data
Choice d
Method
[13]

**********

In OOP, the concept of Polymorphism is

Choice a
Reusability
Choice b
************
Ability to take more than one form
Choice c
Sharing of data
Choice d
Hiding of data
[14]

In OOP program objects communicate with each other through

Choice a
Data
Choice b
Methods

************

Choice c
Classes
Choice d
Objects
[15] In OOP, the concept of wrapping data and methods into a single unit called
classes is known as
Choice a
Data Abstraction
Choice b
Inheritance
Choice c

Polymorphism
Choice d
**************
Encapsulation
[16] Which of the following is TRUE with respect to Dynamic Binding
Choice a
Linking of a procedure call to the code to be executed in response to the call
Choice b
Code associated with a given procedure is not know until time of the call at run time
Choice c
It is associated with inheritance and polymorphism
Choice d
**************
All of the options 1,2,3

[17] Which of the following type of applications OOP can be useful for
Choice a
Real-time Systems
Choice b
Simulation and modelling
Choice c
Decision Support and office automation systems
Choice d
************
All of the options 1,2,3

[18] Java is Platform-independent, What statement explain this feature


Choice a
*******
Java programs can be easily moved from one computer system to another
Choice b
Java systems verify memory access and virus
Choice c
Java can be used to create applications on the networks
Choice d
It provides many safeguards to ensure reliable code
[19]

Java is also popularly known as

Choice a
Web browser
Choice b
Applet language
Choice c
********
Internet language
Choice d

Object language
[20] Which of the following is NOT one of the web browsers
Choice a
********
Coldjava
Choice b
Netscape Navigator
Choice c
Internet Explorer
Choice d
Hotjava
[21] Java is Multithreaded Language, What Statement best explains this feature
Choice a
*********
Java application need not wait for the application to finish one task before
beginning another
Choice b
Java is capable of dynamically linking in U class libraries, methods and objects
Choice c
Java supports functions written in other languages such as C and C++
Choice d
Java uses less amount of memory in environment
[22] API stands for
Choice a
Applet Program Internet
Choice b
Application Package Information
Choice c
Abstract Programming Interface
Choice d
***************
Application Programming Interface
[23] Identify line numbers where errors occur in the following code
1 class sample
2 {
3 public static void main(String[], args[])
4 {
5 System.out.println(Hello);
6 }
7 };
Choice a
Lines 3,7
Choice b
Line 3
Choice c

***********

Line 7
Choice d
Line 5
[24] Identify line numbers where errors occur in the following code
1 Class sample
2 {
3 public static void main(string args[])
4 {
5 int m=10;
6 {
7 int m=20;
8 }
9 }
10 }
Choice a
*************
Lines 1,3,7
Choice b
Line 3,5,7
Choice c
Line 5,7
Choice d
Line 3,5
[25] Identify line numbers where compile errors occur in the following code
1 class sample
2 {
3 public static void display()
4 {
5 byte x=212;
6 float f=100.12;
7 System.out.println("Value of f="+f);
8 System.out.println("Value of x="+x);
9 }
10 }
Choice a
Lines 5,6,7,8
Choice b
Line 5,6
Choice c
Line 7,8
Choice d
***********
Line 5,6
[26] What will be the output of the following program code
class sample
{
public static void main(String args[])
{
int x=10;
int y=15;
System.out.print(x>y?4:3);
}
}

Choice a

*********

3
Choice b
4
Choice c
10
Choice d
15
[27] What is the value of ans if the code of statements are executed
int i = 42+45-48-5;
int j = 5+5-8+2;
int ans = i%j;
Choice a
2
Choice b
***********
8
Choice c
34
Choice d
12
[28] What will be happen when the following code is executed.
class check
{
public static void main(String args[])
{
int m;
System.out.print(m is +m);
}
}
Choice a
Run-time error
Choice b
Compile-time error
Choice c
*************
m is 0
Choice d
No output
[29] What will be the output of the following code, if executed with command line
arguments as follows
java cmdline Java is wonderful
class cmdline
{
public static void main(String args[])
{
for(int i=1;i<args.length;i++)
{
System.out.print(args[i]);
if(i!=args.length)
System.out.print( );

}
System.out.println();
}
}
Choice a
Java
Choice b
Java is
Choice c
*************
is wonderful
Choice d
cmdline Java is wonderful
[30] What will be the output of the following code, if executed with command line
arguments as follows
java cmdline Java is wonderful
class cmdline
{
public static void main(String args[])
{
System.out.println(Number of arguments : +args.length);
for(int i=0;i<args.length;i++)
System.out.print(args[i]+ );
}
}
Choice a
Number of arguments : 4
Java is wonderful
Choice b
4
cmdline Java is wonderful
Choice c
Number of arguments : 3
Java is wonderful
Choice d
cmdline Java is wonderful

You might also like