Originally Posted by
Noct
would it be suitable to make a class named "Object"
Or is there already an Object class that I have yet to hear about?
java.lang.Object
Originally Posted by
Noct
For the method, I am confuse as to why I am suppose to pass a Comparable[] as one of the arguments. Would someone be able to clarify that?
Say you have object A. Object A implements the Comparable interface. This means object A knows how to compare itself to another object. When you call the method for object A, you have to give it another Comparable object to compare to. What you pass in is the other object, say B. Then object A decides if it is larger than, smaller than, or equal to B, and returns the result to where the method call was made.
--- Update ---
Originally Posted by
Noct
Not sure if I posted this in the right section. My apologies in advance.
The "Whats wrong with my code" section is reserved for questions with code.
Thread moved to theory and questions.