Question: Write a program that will implement a standard queue ( not a priority queue) of integers and use a menu driven approach to allow the

Write a program that will implement a standard queue (not a priority queue) of integers and use a menu driven approach to allow the user to 1) Add, 2) Fetch 3) List, and 4) Quit.

Must use separate compilation and follow the notes. (Lang C)

(Please answer quickly. Thank you)

Write a program that will implement a standard queue (not a priority

Here is guide to help you develop a test case for your queue activity: 1. Test to see if can execute program, and exit immediately with no further I/O 2. Test to see if you properly initialized the queue by trying to list and/or pop to confirm Note: Note: Testing to see if empty status is recognized 3. Add multiple items to the queue by repetitively selecting the add option and adding a new/different value each time Note: This will test ability to add to the queue properly 4. Test to see if the values added are stored in the proper order by listing the contents of the queue. Note: Should be listed in same order added since queues are FIFO 5. Fetch a number from the queue Note: This should remove the first number you added to the queue since queues are FIFO 6. List the contents of the queue Note: This will verify the number was removed in previous test and all others remained 7. Add another number to the queue Note: This will help verify that nothing else is altering the front/back pointers incorrectly 8. Fetch another number from the queue Note: This should remove the second number you added to the queue earlier because it is at the front of the queue. 9. Continuing fetching all remaining numbers from the queue until you receive an "empty message" 10. Enter an invalid menu option to test you get an error message 11. Attempt to fetch an item and verify you get the "empty" message 12. Attempt to list the contents and verify you get the "empty" message 13. Add something to the queue 14. List contents of queue 15. Add a second item to the queue 16. List the contents of the queue and verify you get both items Note: These last add and list tests should help you verify if you are correctly setting front/back pointers when you removed last item earlier 17. Fetch both items from the queue and verify they are removed in same order as entered 18. Exit the program

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!