Domanda di colloquio di Microsoft

stack based dsa question , its east its mostly about monotonus stack