Computer Basics - 1
Description: Computer Basics Mix Test - 1 | |
Number of Questions: 27 | |
Created by: Sundari Chatterjee | |
Tags: Computer Basics Mix Test - 1 Computer Basics |
Which of the following statements regarding Math class is/are true?
i. Math class cannot be instantiated and all the methods are static. ii. All the methods are non-static in Math class and so, the Math class can be instantiated. iii. Constructor is always public in Math class. iv. Constructor is always private in Math class.
Which of the following statements is/are true?
i. Primitive data types are passed by value. ii. Java only supports pass by value. iii. Java only supports pass by reference. iv. Primitive data types are passed by reference.
Which of the following statements is/are true?
i. Linked-List is sequential accessing. ii. Linked-List is random accessing. iii. Array-List is random accessing. iv. Array-List is sequential accessing.
Which of the following statements is correct?
i. Final methods can be overridden ii. Final methods cannot be overridden iii. Final fields are constants iv. Final variables can be changed
Which of the following statements is/are true?
i. A local inner class may be final or abstract ii. A local inner class should not be final or abstract iii. A local inner class can only be static iv. A local inner class can have any modifier
Which of the following is true about automatic type conversion in java?
i. Both the variable types should be compatible ii. The destination type is smaller than the source type iii. Both the variables can have any data types iv. The destination type is larger than the source type
Which of the following is true?
i. All transcendental math functions like sin(), cos() etc return float values. ii. All transcendental math functions like sin(), cos() etc return double values. iii. All transcendental math functions like sin(), cos() etc return int values. iv. All transcendental math functions like sin(), cos() etc return long values.
Which of the following is true?
i. Java doesnt support unsigned, positive only integers ii. Java doesnt support signed, positive only integers iii. Java doesnt support unsigned negative only integers iv. Java doesnt support signed negative only integers
Which keyword is used for a variable, which will change the value irrespective of the thread that is being called?
Which of the following is true?
i. Only byte value used in the expression will be promoted to int when the expression is evaluated. ii. Only short value used in the expression will be promoted to int when the expression is evaluated. iii. Both byte and short value used in the expression will be promoted to int when the expression is evaluated. iv.Neither byte nor short value used in the expression will be promoted to int when the expression is evaluated.
How do you get the size of the String in Java?
Which of the following is true?
i. A nested class has access to the members of its outer class. ii. A nested class will never have access to the members of its outer class. iii. A inner class is a non-static nested class. iv. A inner class is a static nested class.
What is the constant variable which is not part of Fload and Double wrapper classes in Java 6?
Which method is not present in String Buffer?
Which of the following options is correct?
i. The Serializable interface has 0 methods ii. The Serializable interface has 1 method iii. The Serializable interface has 2 methods iv. The Serializable interface has 3 methods
Which method is not present in Throwable class?
What is true from the following options?
i. The Reader/Writer class is character oriented. ii. The Reader/Writer class is byte oriented. iii. The InputStream/OutputStream class is character oriented. iv. The InputStream/OutputStream class is byte oriented.
Which is true regarding the following options?
i. If the value of the object is changed, then we call it an immutable object ii. If the value of the object is not changed, then we call it an immutable object iii. If the object cannot be instantiated, then we call it an immutable object iii. If the object can be instantiated, then we call it an immutable object
Which of the following options is true?
i. When an object invokes yield() method, it will not return to ready state. ii. When an object invokes yield() method, it will return to ready state. iii. When an object invokes sleep() method, it will return to ready state. iv. When an object invokes sleep() method, it will not return to ready state.
Pick out what is true from the following options? i. Object instantiated from String Buffer is thread-safe. ii. Object instantiated from String Builder is thread-safe. iii. String Buffer has high and fast performance. iv. String Builder has high and fast performance.
Which of the following is not a method of Object class?
What of the following statements is true about NoSuchMethodException?
i. NoSuchMethodException is caused when the method cannot be called. ii. NoSuchMethodException is caused when the method does not exist. iii. NoSuchMethodException is a Checked Exception. iv. NoSuchMethodException is a Unchecked Exception.
Which method is not final in Object class?
Which of the following options is true?
i. Float and Double classes have only a non-static method i.e. Nan() method.
ii. Float and Double classes have only one static method i.e. Nan() method.
iii. Float and Double classes have one static method i.e. Nan() method, and one non-static method i.e. Nan() method.
iv. Float and Double classes does not have any Nan() method.
Which of the following is true about ClassNotFoundException?
i. ClassNotFoundException is caused when the class is not found. ii. ClassNotFoundException is caused when the class cannot instantiated. iii. ClassNotFoundException is a Checked Exception. iv. ClassNotFoundException is a Unchecked Exception.
Which is true from the following options?
i. Constructors should not have the return type but the methods may or may not have a return type ii. Constructors must have the return type but the methods may or may not have return type iii. Constructors may or may not have the same name as that of the class name but methods must have the same name as that of the class name. iv. Constructors must have the same name as that of the class name, but methods may or may not have the same name as that of the class name
Which of the following options is true?
i. Float and Double classes have only one non-static method i.e. Infinite() method.
ii. Float and Double classes have one static method i.e. Infinite() method, and one non-static method i.e. Infinite() method.
iii. Float and Double classes have only one static method is Infinite() method.
iv. Float and Double classes does not have any Infinite() method.