Question: Amend the classes to include the following functionality. 1 . Modify the method to add animals or bids to the zoo. a . Using filter

Amend the classes to include the following functionality. 1. Modify the method to add animals or bids to the zoo. a. Using filter function, add functionality to ensure that only one object of each animal class can be added to the zoo. For example, zoo can have only one tiger. If we try to add more, print a message stating, animal already added. 2. Amend your looking method to use map and reduce function and create a single string to represent the zoo. 3. Add one method to look at all the canines in the zoo, use a filter function with lambdas for it.4. Add a method to filter out tiger in the zoo and look at them. Use regex to achieve this functionality. 5. Hint: you will have to go over all the animals in the zoo.

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Programming Questions!