CS/SWE 332 Assignment 5
Fall 2020


Goal: Abstraction Functions and Rep-Invariants.
Provide an abstraction function and rep-invariant for the (mutable) Stack example from assignment 4.

  1. Implement the abstraction function (as toString()) and the representation invariant (as repOk()).
  2. Once your code is complete, add some fault (intentionally, if necessary) that results in a violation of the rep-invariant.

    Your fault should be a "missing code" fault. In other words, you should introduce your fault be deleting some code in your (correct) implementation.

    Demonstrate that your faulty code is, indeed, faulty with a call to repOk() from a JUnit test. To help out the GTA, you should document your fault with an easily identifiable comment in your code.

Two more things: Remember that you're deliverable is a story. Remember that part of your group needs to synthesize the solution, and part of your group needs to verify the result.