lab8 passed simulation tests 0 through 2