1.Define a method removeEvery for the class Array Bag that removes all occurrences of a given entry from a bag.
2. An instance of the class Array Bag has a fixed size, whereas an instance of ResizableArrayBag does not. Give some examples of situations where a bag would be appropriate if its size is
a. Fixed.
b. Resizable.
3. Suppose that you wanted to define a class Pile of Books that implements the interface described in Project 2 of the previous chapter. Would a bag be a reasonable collection to represent the pile of books? Explain.
Already registered? Login
Not Account? Sign up
Enter your email address to reset your password
Back to Login? Click here