Hi, this is probably a really stupid question. I am learning java and it's my first time in an OO environment. Trying to write my first multi-class routine and I am having difficulties making the non-main class. This is taken from the head first java book.
My Dog.java file reads:
When I compile I get:
Dog.java:9: Missing return statement
}
^
1 Error
I'm usually pretty good at debugging code, at least in non-OO like C, but I can't seem to figure this one out.
Also, correct me if I'm wrong, but my understanding is that when I'm done I'm going to have several .class files and I'll run the one with main. Can anyone tell me how the JVM finds the correct classes to run? Maybe I'm worrying about things I shouldn't, but it feels weird trusting it to just find the correct file when it's supposed to...