Old Mr. Baker was known for his impeccable calculations. He had a small bakery, and every day, he meticulously recorded the number of loaves he baked. One week, he found the average number of loaves baked per day was thirteen. Determined to maintain his bakery's reputation for consistency, he decided to include the next day's loaf count in his average. However, he wanted to ensure the average for the six days remained a whole number. What was the smallest number of loaves he could bake on the sixth day to achieve this?