calculate percentage and print to file