MathWorks interview question

Data structure regarding queue and stack