Related Questions
What is the correct answer?
4
Two methods cannot have the same name in Java.
What is the correct answer?
4
The default case is always required in the switch selection structure.
What is the correct answer?
4
A thread can make second thread ineligible for execution by calling the suspend (-) method on second thread.
What is the correct answer?
4
DataInput is
A. An abstract class defined is java.io.
B. A class we can use to read primitive data types.
C. An interface that defines methods to open files.
D. An interface that defines methods to read primitive data types.
What is the correct answer?
4
What does the following line of code do?
TextField text=new TextField(10);
A. Creates text object that can hold 10 rows of text.
B. Creates text object that can hold 10 columns of text.
C. Creates the object text and initializes it with the value 10.
What is the correct answer?
4
Which are the valid ways to create DataInputStream streams?
A. new DataInputStream(new File("in.dat"));
B. new DataInputStream(new FileInputStream("in.dat"));
C. new DataInputStream("in.dat");
D. new DataInputStream("in.data","r");
What is the correct answer?
4
The import statement is always the first no comment statement in a Java program files.
What is the correct answer?
4
In evaluating a logical expression of type 'Boolean expression 1&& Boolean expression 2', both the Boolean expressions are not always evaluated.
What is the correct answer?
4
An individual array element that is passed to a method and modified in that method will contain the modified value when the called method completes execution.
What is the correct answer?
4
Consider the following class definitions:
class maths {
student student1;
}
class student {
String name;
}
This code represents:
A. an 'is a' relationship
B. a 'has a' relationship
What is the correct answer?
4
If m and n are int type variables, what will be the result of the expression
'm % n' when m = -14 and n = -3?
What is the correct answer?
4
executeUpdate(------------) returns ___________
B. Returns a ResultSet object
C. Returns an integer value to show the no. of updated rows
What is the correct answer?
4
A package is a collection of
D. classes and interfaces
What is the correct answer?
4
We can over load methods with differences only in their return type.
What is the correct answer?
4
With javadoc, which of the following denotes a javadoc comment?
What is the correct answer?
4
Connection, Statement are interfaces and ResultSet is a class.
What is the correct answer?
4
It is perfectly legal to refer to any instance variable inside of a static method.
What is the correct answer?
4
A JSP file can be stored_________________
A. With the extension .jsp in servlets folder of the jws
B. With the extension .html in public_html folder of the jws
C. With the extension .jsp in public_html folder of the jws
What is the correct answer?
4
To delete a file, we can use an instance of class file.
What is the correct answer?
4
Throwing an exception always causes program termination.
What is the correct answer?
4
Which of the following methods can be used to draw the outline of a square?
What is the correct answer?
4
Which of the following string can be used as mode string for creating a RandomAccessFile object?
What is the correct answer?
4
When present, package must be the first no comment statement in the file.
What is the correct answer?
4
A string object can not be modified after it is created.
What is the correct answer?
4
The length of a string object 's1' can be obtained using the expression s1.length.
What is the correct answer?
4
A variable declared inside the for loop control can not be referenced out side the loop.
What is the correct answer?
4
executeUpdate automatically updates data because___________
A. auto commit is on, by default
B. It performs a hidden commit statement as well
What is the correct answer?
4
Which of the following are not keywords?
What is the correct answer?
4
If you want to assign a value of 99 to the variable year, then which of the following lines can be used within an <applet> tags?
A. number=getParameter(99)
D. <param = radius value ==99>
What is the correct answer?
4
When we implement the Runnable interface, we must define the method