1) Which Java component is responsible for converting bytecode (.class code) into instructions that the operating machine can execute, ensuring code portability? a) JVM (Java Virtual Machine) b) JDK (Java Development Kit) c) IDE (Integrated Development Environment) d) JRE (Java Runtime Environment) 2) What is the correct signature (declaration) of the main method (entry point) in a Java application? a) public void main(String[] args) b) private static int main(String[] args) c) static void main(String args[]) d) public static void main(String[] args) 3) After compiling a Java source file (.java), what is the generated intermediate file that contains the bytecode? a) .out file b) .jar file c) .exe file d) .class file 4) Which Object-Oriented Programming (OOP) principle in Java is implemented using access modifiers (private, public, etc.) to protect and control an object's internal state? a) Abstraction b) Encapsulation c) Polymorphism d) Inheritance 5) In Java, which of the following primitive data types is used to store whole numbers and is the most commonly used type (32 bits)? a) float b) double c) int d) String 6) Which keyword is used in Java to allocate memory and instantiate a new object of a class, calling the constructor? a) class b) void c) new d) this 7) In terms of OOP in Java, what best describes the concept of Inheritance? a) The requirement that a class implements all methods defined in an interface. b) The ability of one class (subclass) to acquire the attributes and methods of another class (superclass). c) The process of converting data types through an explicit cast. d) Bundling data and methods into a single unit while keeping implementation details hidden. 8) What is the default value that an instance variable (non-local) of type boolean receives if it is not explicitly initialized? a) null b) false c) true d) 0 (zero) 9) What fundamental characteristic of Java allows compiled code to be executed on any operating system that has the Java Virtual Machine (JVM) installed? a) Garbage Collection b) Object-Oriented Programming c) Strong Typing d) Platform Independence (Portability) 10) In Java, all code must be contained within which fundamental structure? a) Method b) Class c) Variable d) Object
0%
Java
共用
共用
共用
由
Whatever26662
編輯內容
列印
嵌入
更多
作業
排行榜
顯示更多
顯示更少
此排行榜當前是私有的。單擊
共用
使其公開。
資源擁有者已禁用此排行榜。
此排行榜被禁用,因為您的選項與資源擁有者不同。
還原選項
測驗
是一個開放式範本。它不會為排行榜生成分數。
需要登錄
視覺風格
字體
需要訂閱
選項
切換範本
顯示所有
播放活動時將顯示更多格式。
打開結果
複製連結
QR 代碼
刪除
恢復自動保存:
?