Initially cylinder is at 20. So, as per shortest seek time, the requests will be serviced in the order: 18, 25, 35, 39, 8, 5, 3. So, total no. of seeks
$= (20-18)+ (25-18) + (35-25) + (39-35) + (39-8) + (8-5) + (5-3)$
$= 2+ 7 + 10 + 4 + 31 + 3 + 2 = 59$.
A seek takes 5 msec. So, total seek time = $59 \times 5 = 295 msec.$