CS 210 Challenge Assignments
These assignments are not part of your grade for this course; however, your work on these challenges will be concidered should your grade fall
on the borderline betwee two grades. Most importantly, these challenge assignments will give you a chance to deeping your understanding of some topics
you might find usefull to you in programming data structures later on.
- Linked Lists Challenges As with all challenge assignments, complete the required work and submit it before attempting this challenge. I suggest you copy your Linked List into a new folder and work on the challeges from there.
- Challenge 1: Try creating an ordered linked list. This will require you to chance only one method you have written, but you could also use this to discover that an element is not in the list quicker.
- Challenge 2: Try changing the problem to add at the back (or tail) of the list instead of the front. Does this change how the ListTester class must be written?
- Challenge 3: Try creating a double-linked list as described in the text. This will require you to modify the Node class to include
a pointer to the tail . You will need to modify your add and remove methods to keep both the forward and backward pointers updated. If you list is ordered, your find method could choose the closest route (forward or backward) to find an item assuming the list was evenly populated.
This might be useful for large lists.