its easy
if he walked x miles then he will take x/2 time to travel that distance and he will run for 8-x miles. therefore his time for running will be 8-x/6
total time = time taken while walking + time taken while running
3 = x/2 + 8-x/6
solve this and one will get x= 5 which is the distance he walked. total distance traveled is 8 miles so ratio will become 5/8
if he walked x miles then he will take x/2 time to travel that distance and he will run for 8-x miles. therefore his time for running will be 8-x/6
total time = time taken while walking + time taken while running
3 = x/2 + 8-x/6
solve this and one will get x= 5 which is the distance he walked. total distance traveled is 8 miles so ratio will become 5/8







