19 lines
438 B
C
19 lines
438 B
C
#include <stdbool.h>
|
|
|
|
typedef struct node {
|
|
void *data;
|
|
int key;
|
|
struct node *next;
|
|
} node;
|
|
|
|
typedef struct linkedList {
|
|
node *head;
|
|
} linkedList;
|
|
|
|
linkedList* createLinkedList();
|
|
void insertFirst(linkedList *list, int key, void *data);
|
|
node* deleteFirst(linkedList *list);
|
|
node* find(linkedList *list, int key);
|
|
node* deleteElement(linkedList *list, int key);
|
|
bool isEmpty(linkedList *list);
|
|
int length(linkedList *list); |