Stack implementation using 2 Queues || Data Structures and Programming

preview_player
Показать описание
Stack is a data structure working on the principle of LIFO (Last In First Out). This tutorial demonstrates implementing a Stack using 2 Queues in C.
Рекомендации по теме
Комментарии
Автор

in the push() function, why do we check if Q1[0] = 0? We are supposed to check whether Q1 is empty or not right. If you try to push(0) as an element, it doesn't work bcz of that condition.

nj
welcome to shbcf.ru