Concept:Use the map scale to convert map distance into actual ground distance.Explanation:Given: 31 cm on the map =5 km on the ground.So, 1 cm on the map =5×3=15 km.Now, the distance between towns A and B on the map is 18 cm.Actual distance =18×15 km.Actual distance =270 km.Answer:D. 270 km