What is a package in Java?
A. A way to group related classes and interfaces together.
B. A way to restrict access to a method or variable.
C. A way to define a new class based on an existing class.
D. None of the above.
Answer:A
What is a package in Java?
A. A way to group related classes and interfaces together. B. A way to restrict access to a method or variable. C. A way to define a new class based on an existing class. D. None of the above.