#include<stdio.h>#include<malloc.h>#define MaxSize 100typedef char ElemType;typedef struct{ ElemType date[MaxSize]; int top;}SqStack;void InitStack_luoweicheng(SqStack *&s){ s=(SqStack *)malloc(sizeof(SqStack)); s->top=-1;}void DestroyStack_luoweicheng(SqStack *&s){ free(s);}bool StackEmpty_luoweicheng(SqStack *&s){ return (s->top==-1);}bool Push_luoweicheng(SqStack *&s,ElemType &e){ if(s->top==MaxSize-1) return false; s->top++; s->date[s->top]=e; return true;}bool Pop_luoweicheng(SqStack *&s,ElemType &e){ if(s->top==-1) return false; e=s->date[s->top]; s->top--; return true;}bool GetTop_luoweicheng(SqStack *&s,ElemType &e){ if(s->top==-1) return false; e=s->date[s->top]; return true;}