1. The following line of Java code
int e = 2.7182;
results in …
- A compile-time error
- an “incompatible type” execution error
2. Every Java application…
- is interpreted by the Java Virtual Machine from a”*.java” file.
- built as a standalone program must have a single mainmethod in one of the classes contained in the application’s sourcecode.
- uses garbage collection in the compilationstage.
3. A staticmethod…
- belongs to the class rather than to an instantiated”object” of the class.
- can call non-static instance methods.
- cannot return a value.
Answer
1.A compile-time error2.uses garbage collection in the compilation stage.3.belongs to the class rather than to an instantiated “object” of the class.