Modified hints algorithm, updated unit tests.