Update 0225.用队列实现栈.md

This commit is contained in:
lfeng
2021-10-08 10:12:08 +08:00
committed by GitHub
parent 9badd38a38
commit ff7c57a7d0

View File

@ -112,7 +112,7 @@ public:
# 优化
其实这道题目就是用一个队就够了。
其实这道题目就是用一个队就够了。
**一个队列在模拟栈弹出元素的时候只要将队列头部的元素(除了最后一个元素外) 重新添加到队列尾部,此时在去弹出元素就是栈的顺序了。**