- 4
- 0
- 约5.11千字
- 约 9页
- 2019-07-29 发布于安徽
- 举报
实用文档
标准文案
//模拟资源管理器
#include stdio.h
#include string.h
#include conio.h
#include stdlib.h
#define max 100
typedef struct Tree
{
char data[10];
struct Tree *child,*brother;
}*CsTree,Tnode;
typedef struct
{
char data[max][10];
int top;
}seqstack;
int pushstack(seqstack s,char *ch)
{
if(s.top==max-1)
{
printf(栈满!\n); return 0;
}
s.top++;
strcpy(s.data[s.top],ch);
return 1;
}
void popstack(seqstack s)
{
if(s.top==-1)
{ printf(栈空!\n); return;}
else
s.top--;
}
void printstack(seqstack s)
{
int i=0;
if(s.top==-1)
{ printf(栈空!\n); return;}
while(i=s.top)
{
printf(%s ,s.d
原创力文档

文档评论(0)