全部评论 1

  • #include<bits/stdc++.h>
    using namespace std;
    char st[100],TOP=0;
    //入栈
    void push(char x){
    TOP++;
    st[TOP]=x;
    }
    //出栈
    void pop(){
    TOP--;
    }
    //取栈顶元素
    int top(){
    return st[TOP];
    }
    //判断栈是否为空
    bool empt

    2023-10-22 来自 北京

    0

热门讨论