Testing the Linked List
If you haven’t already created some tests, now is a good time. Add main
and play with the different functions to test they work as expected.
Here is a simple version that I used to test this out. We should add some extra checks to make sure that we remove different elements (the first, last, and only for example) but this is a pretty good start on what is a nice bit of memory management code to think through.