主页
C++
C++ 栈
demo_stack_empty2
运行 ❯
×
更改方向
保存代码
更改主题
#include
#include
using namespace std; int main() { stack
cars; cars.push("Volvo"); cars.push("BMW"); cars.push("Ford"); cars.push("Mazda"); // Check if the stack is empty cout << cars.empty(); return 0; }