Circumference C=2pi*r
But in question C=40pi
This implies that 2pi*r=40pi
This implies that r=20 in.
d=2*r=40 in.
Hope this helps :)