1. Define the method union, as described in Exercise 5 of Chapter 1, for the class ResizableArrayBag.
2. Define the method intersection, as described in Exercise 6 of Chapter 1, for the class ResizableArrayBag.
3. Define the method difference, as described in Exercise 7 of Chapter 1, for the class ResizableArrayBag.
4. Write a Java program to play the following game. Randomly select six of the cards Ace, Two, Three, . . ., Jack, Queen, and King of clubs. Place the six cards into a bag. One at a time, each player guesses which card is in the bag. If the guess is correct, you remove the card from the bag and give it to the player. When the bag is empty, the player with the most cards wins.
Already registered? Login
Not Account? Sign up
Enter your email address to reset your password
Back to Login? Click here