In the Two() constructor, it will first call the super() - in this case - the Super class - because Two extends Super - this will print "super" and then the constructor of Two continues and prints "two".
OCPJCP 6.0 | OCPJWCD 5 | SpringSource Certified Spring Professional - Spring 3.0
Hauke Ingmar Schmidt
Joined: Nov 18, 2008
I am sorry, what I wrote seems to be incorrect. I apologize.
The class must be loaded for the declaration of a reference variable.
I used to think this was right. While debugging a class loader problem, it turned out that the JVM I was running did not load classes unless they needed to be instantiated or a static call was made. When a reference was encountered the class was not loaded.
I am not sure if there is a spec out there that mandates when a class should be loaded. I would question if that needs to be part of a spec either. So as to the correctness of any answer, I would not be too worried since SCJP does not expect you to know when a class is loaded. It expects you to know "how" a class is loaded and what gets called in order.