Skip to content

UMK-Data-Science/queue-tutorial

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 
 
 

Repository files navigation

Tutorial Week 13 - Queue

Please answer all questions and read carefully :octocat:

Instructions

This tutorial consists with 2 questions: Linear Queue Array and Circular Queue Array ⭐

Exercise 1 - Linear Queue Array

Using Linear Queue Array technique, write a program to store 5 values as listed below:

Input: 5, 10, 15, 20, 25

Next, dequeue value 5 and 10 and display the output as below:

Peek Value is: 15
Queue is: 15, 20, 25

Exercise 2 - Circular Queue Array

Using Circular Queue Array technique, write a program to store 5 values as listed below:

Input: 10, 20, 30, 40, 50

Next, dequeue value 10, 20 and 30 and insert new element on empty space with 20, 40 and 60. Display the output as below:

Peek Value is: 20
Queue is: 20, 40, 60, 40, 50

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published