Study sets, textbooks, questions
Upgrade to remove ads
Terms in this set (50)
Which of the following methods of the java.io.File can be used to check whether a file read or not?
Select a correct statement about interfaces.
A. An interface is a class that has method implementations with no data.
B. An interface is an abstract class with no data.
C. In its most common form, an interface is a group of related methods with empty bodies.
D. An interface is a class that has at least one abstract method.
Which of the following should always be caught?
A. Errors other than assertion errors
B. Assertion errors
C. Checked exceptions
D. Runtime exceptions
Which of the following methods of the java.io.File can be used to check whether a file exists or not?
If all three top-level elements occur in a source file, they must appear in which order?
A. Imports, package declarations, classes/interfaces/enums
B. Classes/interface/enums, imports, package declarations
C. Imports must come first; order for package declaration and class/intereface/ enum definitions is not significant
D. Package declaration, imports, class/interface/enum definitions.
E. Package declaration, must come first; order for imports and class/intereface/ enum definitions is not significant
Which of the following classes implement java.util.List?(select two)
Which of the following is true?
A. A class inherits constructors from its superclasses.
B. A class inherits constructors from its direct superclass only
C. A class inherits constructors from its superclasses when the program points out that.
D. A class does not inherit constructors from any of its superclasses.
Which of the following collections supports accessing elements through keys and values?
The process of identifying common features of objects and methods is
Which of the following statement(s) is (are) true?
1) An abstract class cannot have any final methods.
2) A final class may not have any abstract methods.
A. Both statement 1 and 2
B. Only statement 1
C. Only statement 2
D. None of them
Select the correct statement:
A. An object reference cannot be cast to an interface reference
B. An object reference can be cast to an interface reference when the object implement all methods of the referenced interface.
C. An object reference can be cast to an interface reference when the object implements the referenced interface.
D. An object reference can always be cast to an interface reference.
If you wanted to find out where the position of the letter v (ie return 2) in the string s containing "java" , which of the following could you use?
A(n)____is a characteristic that describes an object
Which of the following statement can be used to call a constructor of the super class from its sub-class?
Referring to the above, what data type could be returned by method check4Biz() ?(select two)
Other Quizlet sets
ECM part. 1 - Shoulder muscles Axioappen…
Phys Exam 3