Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Question : Develop a C++ program that maintains a linked-list based bag structure for customer. Each custome... Develop a C++ program that maintains a linked-list

Question: Develop a C++ program that maintains a linked-list based bag structure for customer. Each custome...

Develop a C++ program that maintains a linked-list based bag structure for customer. Each customer has name, ID, DOB, and address. See for details: - name: One word string, having only a-z and A-Z. The first letter is capitalized, the rest are lowercase. Randomly generated in your program. - ID: positive whole number, between 1000-9999. Randomly generated in your program. It is unique for each customer. - DOB: a string, in the format of "Jan 15, 2001". Randomly selected in your program. - Address: a string, in the format of "Commerce, TX". Randomly generated in your program. Make sure use at least 5 city names with at least three states You should write a class to maintain a bag, which is similar to in-class example. Your class should provide these functions: - Create a bag to keep customers - Add a new customer (all data pieces will be randomly created) - Search a customer with ID - List names and IDS of the customers who are specified by an address. (for instance, "Houston, TX") - Remove a customer with ID - Remove the last inserted customer - Remove all customer (do not forget to free structs from memory) - Print the number of customer in the bag Your program should automatically add 1000 customers to the bag once the program is run.

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Spomenik Monument Database

Authors: Donald Niebyl, FUEL, Damon Murray, Stephen Sorrell

1st Edition

0995745536, 978-0995745537

More Books

Students also viewed these Databases questions

Question

Who needs to be involved in formulating organizational strategy?

Answered: 1 week ago

Question

5. How would you describe your typical day at work?

Answered: 1 week ago