Finished all functionality. Still need to account for 'tie' case