DataStructures-and-Algorithms-eclipse
Invariants
- Invariants are conditions that remain unchanged as the algorithm proceeds.For example, in the BubbleSort data items to the right of the out are sorted throughout. Invariants are helpful in debugging. Signal an error if the invariant is not true.