Exercise 5.1 class Card3.java and method hashCode(), whats the purpose of this method its not called from anywhere? Is it also necessary to add the @Override to the methods: public boolean equals(Object obj), public int hashCode(), public String toString()
The program runs fine. I'm thinking the hashCode method may have been put in there to randomize the cards and suit, if user input was used. But since we explicitly declare the card and suit in the main method, its kind of pointless. -- To post to this group, send email to [email protected] To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://groups.google.com/group/javaprogrammingwithpassion?hl=en
