1. define the header file
To implement the definition of the stack method, note that the global static array is used here. The ability to protect data in this way.
main.c . Implementing Storage
Queue, creating a header file queue.h
Create queue.c
Implement Main function
Single linked list
when defining a header file, it is best to use :
#ifndef variables A
#define variables A
Declarations such as function declarations and struct declarations
#endif
This way, you can avoid the negative effects of repeated calls to the header file.
Defining header Files link.h : (Note plus extern )
definition link.c
Writing main.c
4. Doubly linked list
Create link.h header File
Write link.c file
Implement main.c Method
Copyright notice: This article blog original articles, blogs, without consent, may not be reproduced.
Heap, queue, single list, doubly linked lists