DEVFYI - Developer Resource - FYI

What is a Java package and how is it used?

Java Interview Questions and Answers (part 2)


(Continued from previous question...)

347. What is a Java package and how is it used?

A Java package is a naming context for classes and interfaces. A package is used to create a separate name space for groups of classes and interfaces. Packages are also used to organize related classes and interfaces into a single API unit and to control accessibility to these classes and interfaces.

(Continued on next question...)

Other Interview Questions