list.c
, list.h
,
testList.c
from
here into your lab9
directory.
int length(Node head)
Node sorted_insert(Node head, int val)
Node insertAt(Node head, int index, int value)
.
Further clarifications about each function is provided inside list.c
file. We have also provided all the tests in testList.c
for you. Make sure you familiarise yourself with the testfile as in the future you will be expected to write tests yourself.
Note: for this lab there will be no dryrun set up. You have been provided with all the tests and expected to make sure your program compiles and runs locally before submitting.
$ give cs1917 lab9 list.c