Can I import same package/class twice? Will the JVM load the package twice at runtime? - JAVA Interview Questions

Can I import same package/class twice? Will the JVM load the package twice at runtime?


One can import the same package or same class multiple times. Neither compiler nor JVM complains anything about it. And the JVM will internally load the class only once no matter how many times you import the same class.



Click Here to See Answer .....
Did you like this article ?
Subscribe to my RSS feed and get more JAVA Question, and Guideline, Plus a lot more great advice to help your Software Career.

0 comments:

Related JAVA Questions Posts