ZE-Standard-Libraries/stack/stack.c
Saturneric c1568c3a5f 测试
2018-06-12 13:51:42 +08:00

13 lines
588 B
C
Raw Blame History

This file contains invisible Unicode characters

This file contains invisible Unicode characters that are indistinguishable to humans but may be processed differently by a computer. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

#include "./stack_expand.h"
int stack(void) {
Stack *t_stack = initStack();
for (int i = 0; i < 10; i++) {
pushStack(t_stack, snodeWithInt(i));
}
for (int i = 0; i < 10; i++) {
printf("%d", getValueByIntForSNode(popStack(t_stack)));
}
releaseStack(t_stack);
return 0;
}