about summary refs log blame commit diff
path: root/linked_list.h
blob: fcea7a05d7b9878c8ff26877fca4fb6f01e183a6 (plain) (tree)
























                                                       
#ifndef _LINKED_LIST_H
#define _LINKED_LIST_H

typedef struct Node
{
	int x, y;
	struct Node *next, *prev;
} Node;

typedef struct LinkedList
{
	Node* head, *tail;
} LinkedList;

Node *initialise_node(void);
void free_node(Node *);
LinkedList *initialise_linked_list(void);
void free_linked_list(LinkedList *);
void append_linked_list(LinkedList *, int, int);
void remove_tail_linked_list(LinkedList *);
void print_linked_list(LinkedList *, void (*)(void *));


#endif