Matthew Brown wrote:The Small class inherits the count() method, but because it's not a static method it belongs to instances of the class. So you need a Small object to be able to call the count() method on it. There are no instances created until you create one.
Just to show it's not a problem with the inheritance: you'll still have the same problem if you move the count() method to the Small class (try it out).
thanks.. I'm stupid.. I had read that just recently you know. It went out of my mind. I guess I need more practice.. I am preparing for OCJP and am from a Hardware background, so oops programming concepts are new to me.
anyways..appreciate the help