Program 3:
- Program Description
- Grading Criteria:
- List Class Correctness (50% == 5 points)
- empty, size, front (0.5 points)
- size
- boundary: list empty
- typical: list not empty
- push_front, pop_front (0.5 points)
- push_front
- boundary: list empty
- typical: list not empty
pop_front
- boundary: list size == 1
- typical: list not empty
- assert: !empty()
- ==, != (1 point)
- insert, erase (1 point)
- insert
- boundary: list empty
- boundary: insert at end
- typical: insert not at end
- erase
- boundary: not in list
- boundary: erase list tail, list size == 1
- boundary: erase list tail, list size > 1
- typical: not erase list tail
- set itr.d_cur
- =, clear, copy (1 point)
- =
- clear
- delete via loop
- d_tail = NULL
- copy
- runtime (0.5 point freebie)
- invariant (0.5 points)
- all d_prev and d_next link to a non-null node
- all d_next.d_prev == cur
- all d_prev.d_next == cur
- done in linear O(n) time
- Testing (20% == 2 points)
- Test various list sizes
- Test all functions
- Test various combinations of functions
- Support Documents (15% == 1.5 points)
- Implementation plan
- Code summary
- Programming Style (15% == 1.5 points)
- Cover sheet (0.5 points)
- Code printout (0.5 points)
- Output printout (0.5 points)