Related Questions
What is the correct answer?
4
When we implement the Runnable interface, we must define the method
What is the correct answer?
4
The modulus operator (%) can be used only with Integer operands.
What is the correct answer?
4
It is an error to have a method with the same signature in both the super class and its subclass.
What is the correct answer?
4
Give file is a file object, which of the following are legal statements to create a new file.
B. FileOutputStream fos=new FileOutputStream(file);
C. FileInputStream fis=new FileInputStream(file);
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
Any class may be inherited by another class in the same package.
What is the correct answer?
4
Which of the following keywords are used to control access to a class member?
What is the correct answer?
4
Which of the following represent legal flow control statements?
What is the correct answer?
4
A package is a collection of
D. classes and interfaces
What is the correct answer?
4
EJBs can be of the following type(s)
None of the above
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
A final class may not have any abstract method.
What is the correct answer?
4
Connection, Statement are interfaces and ResultSet is a class.
What is the correct answer?
4
Given the code
String s = new String("abc");
Which of the following calls are valid?
What is the correct answer?
4
When the string objects are compared with ==, the result is true If the strings contain the same values.
What is the correct answer?
4
The break statement is required in the default case of a switch selection structure.
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
When X is a positive number the operations x>> 2 and x>>>2 both produce the same result.
What is the correct answer?
4
class.forName(...) creates an instance of java ODBC driver
What is the correct answer?
4
With javadoc, which of the following denotes a javadoc comment?
What is the correct answer?
4
A class may be both abstract and final.
What is the correct answer?
4
In RMI we invoke client method from remote server
What is the correct answer?
4
If a=10 and b= 15, then the statement x =(a>b)?a:b; assigns the value 15 to x.
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
Servlet has ___________
C. All of the above methods.
What is the correct answer?
4
Consider the following class definition.
Class Student extends String
{
}
What happens when we try to compile this class?
A. Will not compile because class body is not defined
B. Will not compile because class is not declared public
C. Will compile successfully.
D. Will not compile because String is abstract
What is the correct answer?
4
The programmer must explicitly create the system .in and system .out objects.
What is the correct answer?
4
If a=10 and b= 15, then the statement x =(a>b)?a:b; assigns the value 15 to x.
What is the correct answer?
4
A constructor must always invoke its supper class constructor in its first statement.
What is the correct answer?
4
For all insert, update, delete, query operations on a database, ResultSet object creation is mandatory.