Add score report. Major refactoring. Start adding unit tests.