First of all, one gallon is eight pints. So now you have to compare. That will be:
1 gallon=8 pints
5 gallons= Y
Y is the unknown value. Next you have to cross and multiply. So;
5 x 8=1 x Y
40=Y
So Y=40 pints
5 gallons is 40 pints. Hope that helped. Goodluck