Let the length of the journey from home to work be x km.

Recall that

`text(speed) = text(distance)/text(time)`

So

`text(time) = text(distance)/text(speed)`

We must use the same time units throughout. We will use hours.

Now

` 50\ text(minutes)=50/60=5/6text(hours)`

In the forward journey, the car's time was `x/30` hours.

For the return journey, the time was `x/40` hours.

The total time was `x/30+x/40=5/6\ text(hours)`

So `(4x+3x)/120=(7x)/120=5/6`

This gives us `7x=(5xx120)/6=100`

That is `x=100/7=14.286`

So the distance from home to work is 14.3 km.