Hi I am Ankur and have been coding with java for few years now..I have read Head first Java The Complete Reference by Herbert Schildt earlier and recently I came across a major
If you do not supply a no-arg constructor the compile supplies one for you, as long as there are no other constructors defined. So in your example the compiler will insert the no-arg student() constructor if you comment out you student() constructor.