setting up the tally method