Java OCA OCP Practice Question 48

Question

Which statements about Java are true?

  • I. The java command can execute .java and .class files.
  • II. Java is not object oriented.
  • III. The javac command compiles directly into native machine code.
  • A. I only
  • B. III only
  • C. II and III
  • D. None are true.


D.

Note

The java command can only execute compiled .class files, so I is false.

Java is object oriented, so II is also false.

The javac command compiles into byte-code, which must be run in a Java virtual machine (JVM), and is not native machine code, so III is false as well.

Option D is the correct answer.




PreviousNext

Related