Pergunta de entrevista da empresa Apple

What is a stack vs a queue

Respostas da entrevista

Sigiloso

1 de nov. de 2017

Stack last in last out, queue first in last out

Sigiloso

2 de ago. de 2018

Stack is last in first out and queue is first in first out. Think of a stack of plates where the last plate in is the first out. For queue, think of a line for a movie ticket where the first in line is the first out.