C_DS_AIgo/linked_list_stack.h

45 lines
435 B
C
Raw Permalink Normal View History

2025-03-25 18:09:23 +08:00
#ifndef LINKED_LIST_STACK_H
#define LINKED_LIST_STACK_H
#define elem_type int
typedef struct stack_node
{
elem_type value;
struct stack_node *next;
}stack_node;
typedef struct stack_linked
{
stack_node *top;
int size;
}stack_linked;
// <20><>ʼջ
stack_linked* init_stack_linked(void);
// <20><>ջ
void push_stack_linked(stack_linked* s, elem_type value);
// <20><>ջ
int pop_stack_linked(stack_linked* s);
#endif