Semtech Interview Question

Write code for queue using stack.