Ok guys, I'm really hoping you can help me out with this one because I'm at the end of my rope in trying to understand the following:
I am confused about what the output of this should be...my study guide shows:
animal
black
animal
black
I am guessing that Pony is called in the main method first (but how it returns Animal is beyond me). Then within the Pony class, the superclass constructor is called (Horse) and passed the
string "black". Third, comes the string "animal" (from the Animal constructor of the Animal class). And lastly, the "new Horse" that was assigned the string "black".
I'm sure this is ALL totally wrong, but can someone please explain the order in which this is executed in the simplest terms possible. Also, what is the purpose of the Pony() constructor in the Pony class? and are all of these constructors implicitly declared as super?