Question: Using the linked list in C program abstract data type described Queue ADT, write a menu-driven user interface to test each of the operations in

Using the linked list in C program abstract data type described Queue ADT, write a menu-driven user interface to test each of the operations in the ADT. Any errors discovered during the processing should be printed as a part of the test result. A suggested menu is shown below.

A. Enqueue data into queue

B. Dequeue and print data

C. Print data at the front

D. Print data at the rear

E. Print entire queue

F. Print queue status: Empty

G. Print queue status: Full

H. Print number of elements and quit

Test your program with the following test cases. You may include additional test cases after you have executed the tests shown below.

a. Print queue status, Empty (F).

b. Dequeue and print data (B). Should return error.

c. Enqueue data into queue: 5 (A).

d. Enqueue data into queue: 8 (A).

e. Print queue status, Empty (F).

f. Print queue status, Full (G).

g. Print data at the front (C).

h. Print data at the rear (D).

i. Print entire queue (E).

j. Print number of elements in queue (H).

k. Dequeue and print data (B).

l. Dequeue and printdata (B).

m.Dequeue and print data (B). Should return error.

n. Enqueue data into queue: 14 (A).

o. Print data at the front (C).

p. Print data at the rear (D).

q. Enqueue data into queue: 32 (A).

r. Print data at the front (C).

s. Print data at the rear (D).

t. Destroy queue and quit (I).

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!