We have three different velocities. Downhill velocity (Dv), Level ground velocity (LGv), and Uphill velocity (Uv). We need to find the level ground velocity to find the time. Initially, the question says that:

Then we have "A train goes twice as fast downhill as it can go uphill". Mathematically this means:

We can find Uv:

The next information is "and 2/3 feet as fast uphill as it can go on level ground". 2/3 in decimal is 0.6666, so we can round it to 0.67.
2/3 feet as fast means that Uphill velocity is greater than level ground velocity. We can say that:

We can find LGv:

Now, to find the time we can apply the medium velocity equation above:



