📄 single_list.h
字号:
/**Author jmanous..*//**A Little nice list with n complexity.Hope not so may SIGSEGV*/enum { ASCII, SOUND, MULTIMEDIA, NOTYPE};typedef struct sNode { int id; int type; int size; struct sNode* next;}Node_sl;/*Call this to get a new Head*/Node_sl *CreateNew(void);/*Insert a node with id and type.Call this with a head node.Resulting list will be ordered by id return 1 on succes , 0 on failure*/int Insert_hs (int id,int type,int newsize ,Node_sl* head);int Insert_sl (int id,int type,Node_sl* head);/*Delete elem with id */int Delete_sl(int id , Node_sl* head);/*Because list is ordered, this will return o node itself if exists or the previous node where it should be*/Node_sl *Find_sl(int id , Node_sl* head);/*Print list from head Node..(Or anything else xD);*/void print_sl( Node_sl* head);
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -