Which is true?

  1. The java command can access classes from more than one package, from a single JAR file.

  2. JAR files can be used with the java command but not with the javac command.

  3. In order for JAR files to be used by java, they MUST be placed in the /jre/lib/ext sub-directory within the J2SE directory tree.

  4. When a part of a directory tree that includes subdirectories with files is put into a JAR file, all of the files are saved in the JAR file, but the subdirectory structure is lost.


Correct Option: A

Find more quizzes: