V = 800 cm3 = πr2h (This is the constraint that ties r and h)
Cost of can material is proportional to surface area of the can without the top:
C = k (2πrh + πr2) (This is the function to minimize)
Substitute h = 800/πr2
C = k(2πr*(800/πr2) + πr2) = k(1600/r + πr2)
dC/dt = k(-1600/r2 + 2πr) = 0
solve for r and use V relation to solve for h (2nd derivative is >0, min)
Please consider a tutor. Take care.