Some test cases. Algorithm not working quite right. May need to rethink much of it.