Question: Write a program that creates an ArrayList of pets .An item in the list is either a Dog or a Cat. For each pet, enter

Write a program that creates an ArrayList of pets .An item in the list is either a Dog or a Cat. For each pet, enter its name and type (c for cat and d for dog). Stop the input when the string STOP is entered for the name. After the input is complete, output the name and type for each pet in the list.

OOP C++

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 Databases Questions!