0
How to compare certain content of 2 stacks?
Stack: ABBA madam evol im Queue: mi love madam ABBA how to compare ABBA from stack and ABBA from queue?
1 ответ
+ 4
Assuming you have stack/queue of chars, you might write a loop that consumes one element from each container, and compares them one by one. If there is any difference, break the loop.