Quiz_Index

Add Question

Question Option1 Option2 Option3 Option4 Option5 Answer
Which of the following are true? The Void class extends the Class class The Float class extends the Double class. The System class extends the Runtime class. The Integer class extends the Number class. None Of These D Edit | Details | Delete
Exceptions can be caught or rethrown to a calling method. True False A Edit | Details | Delete
Because finalize () belongs to the java.lang.Object class, it is present in all ___. objects classes methods B Edit | Details | Delete
The this reference is used in conjunction with ___methods. static non-static B Edit | Details | Delete
Which of the following statements can be used to describe a public method? It is accessible to all other classes in the hierarchy It is accessablde only to subclasses of its parent class It represents the public interface of its class The only way to gain access to this method is by calling one of the public class methods Both A,C E Edit | Details | Delete
The switch statement does not require a break. True False B Edit | Details | Delete
Character literals are stored as unicode characters. True False A Edit | Details | Delete
Strings are instances of the class String. True False A Edit | Details | Delete
What is default layout manager for panels and applets? Flowlayout Gridlayout BorderLayout A Edit | Details | Delete
Which one of the following does not extends java.awt.Component CheckBox Canvas CheckbocGroup Label C Edit | Details | Delete
Which one does not have a valueOf(String) method Integer Boolean Character Long Short C Edit | Details | Delete
Which of the following are Java reserved words? 1. run 2. import 3. default 4. implement 1 and 2 2 and 3 3 and 4 2 and 4 1,2,3 and 4 B Edit | Details | Delete
You need to store elements in a collection that guarantees that no duplicates are stored. Which one of the following interfaces provide that capability? Java.util.Map Java.util.List Java.util.Collection None of the above A Edit | Details | Delete
What allows the programmer to destroy an object x? x.delete() x.finalize() Runtime.getRuntime().gc() Only the garbage collection system can destroy an object. D Edit | Details | Delete
Which of the following are valid calls to Math.max? 1. Math.max(1,4) 2. Math.max(2.3, 5) 3. Math.max(1, 3, 5, 7) 4. Math.max(-1.5, -2.8f) 1, 2 and 4 2, 3 and 4 1, 2 and 3 2, 3 and 4 A Edit | Details | Delete
Which will contain the body of the thread? run(); start(); stop(); main(); A Edit | Details | Delete
Which two of the following methods are defined in class Thread? 1. start() 2. wait() 3. notify() 4. run() 5. terminate() 1 and 4 2 and 3 3 and 4 2 and 4 A Edit | Details | Delete
Which is true about a method-local inner class? It must be marked final. It can be marked abstract. It can be marked public. It can be marked static. B Edit | Details | Delete
What is the numerical range of a char? -128 to 127 -215to 215 0 to 32767 0 to 65535 D Edit | Details | Delete
Which is a valid keyword in java? unsigned interface string Float B Edit | Details | Delete