Question: Using C# Write 2 classes that implement a stack with push, pop and peek operations. One should be called StackL and internally should store the

Using C#

Write 2 classes that implement a stack with push, pop and peek operations. One should be called StackL and internally should store the data in a series of Nodes as a singly linked list. The other, StackO, can use a different data structure of your choice. Write 2 classes that implement a queue with enqueue and dequeue operatons. One should be called QueueL and internally should store the data in a C# linked list. The other, QueueO, can use a different data structure of your choice.

Write a console application to determine the time required to perform the push/pop or queue/dequeue operations on your stacks and queues. Make an instance of a C# stack and a C# queue. Get the time required to push 10,000,000 values onto each stack and then get the time required to pop 10,000,000 values from each stack. Repeat the process using the queue and dequeue operations with the queues.

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!