Appearance
栈,后进先出
const stack = [] stack.push(1) stack.push(2) stack.pop() stack.pop()
根据栈的特性,自然是应用在 后进先出 的场景,例如判断括号是否正确的关闭,十进制转二进制(因最后需要倒序输出)