Most of the time, Homework questions are pretty awful.
To me, the classic scenario is this:
Kid A gets an assignment, is too lazy to think or do some reading, signs up for SO, posts a single ill-phrased question (possibly full of l33tsp34k and lols), takes the first answer that compiles, copies / pastes it into his assignment, usually without commenting, accepting or upvoting any answer. Kid A is then never seen again on SO. (there are fortunately many counter-examples to all of the mentioned aspects, I know, I'm just painting everything black)
In addition: the assignments they get are often awful. There are many lazy teachers out there that haven't updated their material in the last 15 years and hand out Assignments and Reference Material regarding ancient data structures like Vectors, Hashtables and Enumerations (all of these are unofficially deprecated in Java and have been replaced by ArrayList, HashMap and Iterator, respectively, more than 10 years ago).
Also, the OOP concepts taught are often awful. In the above question, there was an inheritance structure of either Person is-a Thread or Card is-a Thread (the OP wasn't really clear about that), which is such an appalling design that I just can't ignore it. Domain classes should never inherit from infrastructure classes!
Given all of the above context: I don't think I am doing anybody a favor by providing a literal answer.
Not the OP
Sure, it might give him a good grade in the assignment, but a) it solves the problem for him instead of teaching him how to solve it. That's how dumb people are made. That's right: nobody is dumb, but they can be made dumb by others :-) b) he will believe the bad practices are good practices and carry on like his teacher taught him to. brrrr.
Not the site
Answering such a question with a literal answer means littering SO with uncommented bad questions that have simple accepted answers. Readers will thereby think the question context is valid and / or a best practice (especially since they are usually asked from a University context, after all a University is where the smart people are, isn't it?)
Sorry, I just won't do it. I will not tell the OP how to solve his question if there is a major flaw in the question, whether it's his fault or not.
In my opinion, people get smart by learning how to ask the right questions. So answering their wrong questions is the worst thing I can do to them.