多应用+插件架构,代码干净,二开方便,首家独创一键云编译技术,文档视频完善,免费商用码云13.8K 广告
<div id="div5"><h4> 5, 用两个栈实现队列 <h4></div> ```javascript const outStack = [], inStack = []; function push(node) { // write code here inStack.push(node); } function pop() { // write code here if (!outStack.length) { while (inStack.length) { outStack.push(inStack.pop()); } } return outStack.pop(); } ```