1st case
car travel 30 km in 1 hour
2nd case
car travel 40 km in 1 hour
3rd case
car travel 30 km in 2 hours
so total distance taken by car
= 30+ 40+ 40
= 110 km
total time taken
= 1 + 1 + 2 = 4 hours
average speed
= total distance / total time
= 110 / 4
= 27.5 km/h
so average speed is 27.5 km/h.