The Demons Command Each Other
From Huben's Wiki
(→(B) Calling Between Classes) |
|||
Line 60: | Line 60: | ||
* The third line of main() shows another way to invoke the speak() of DayTheEarthStoodStill. Why does this work? | * The third line of main() shows another way to invoke the speak() of DayTheEarthStoodStill. Why does this work? | ||
* What rule would you make to explain why sometimes you can call with just the name of a method and other times you need something more complex? | * What rule would you make to explain why sometimes you can call with just the name of a method and other times you need something more complex? | ||
+ | * If you are looking at Nietzsche and hit run, for once the error message makes sense. Why does this give an error? | ||
==(C) Method Calls In Real Programs== | ==(C) Method Calls In Real Programs== |