Now everbody wants "water counters" LOL
You thought 8, I thought 7. What did the meter say after each fill ? If you divide 48 by 4 fills, you get 12 gallons per fill.
So let's do the HOT. Wash 12
Rinse 6 + 6 + 6 ................. .18
Now the COLD ........Wash 0
Rinse 6 + 6 + 6 ................. 18
TOTAL ............................48
HURRAY FOR ARITHMETIXXXXXXX Not a whole cigar, but close. The extra gallon of hot must fill the black hole, yes ?