aboutsummaryrefslogtreecommitdiff
path: root/linked_list_test.c
diff options
context:
space:
mode:
Diffstat (limited to 'linked_list_test.c')
-rw-r--r--linked_list_test.c29
1 files changed, 29 insertions, 0 deletions
diff --git a/linked_list_test.c b/linked_list_test.c
new file mode 100644
index 0000000..a71a1ff
--- /dev/null
+++ b/linked_list_test.c
@@ -0,0 +1,29 @@
1#include <stdio.h>
2#include <stdlib.h>
3#include "linked_list.h"
4
5int main(){
6
7 node* ll = malloc(sizeof(node));
8 ll->value = 1;
9 ll->next = NULL;
10
11
12 print_ll(ll);
13 reverse_ll(&ll);
14 print_ll(ll);
15 /* delete_node(&ll, 0); */
16
17 /* print_ll(ll); */
18 /* printf("The length of ll is %d\n", count_ll(ll)); */
19
20 /* delete_node(&ll, 0); */
21 /* print_ll(ll); */
22 /* printf("The length of ll is %d\n", count_ll(ll)); */
23 /* printf("%d\n", search_node(ll, 10)->value); */
24
25 /* printf("%d\n", get_value(ll, 3)); */
26
27 /* free_ll(ll); */
28 return 0;
29}