请问如何将一个栈置空啊?
#include<stdio.h>
#include<stdlib.h>
#define STACK_INIT_SIZE 100;
#define STACKINCREMENT 10;
typedef struct{
int *base;
int *top;
int stacksize;
}SqStack;void ClearStack(SqStack &S)
{
S.top = S.base ;
S.stacksize = STACK_INIT_SIZE;
}
这要这样就可以了吗?感觉不太对,求指教~