Don't be embarrassed at not solving that problem: if you're out of practice then it's probably not at all obvious what to do. Right now I'm way too tired to think properly, too.
Maybe a trial-and-error approach is the most intuitive way to solve it. If Jonas cycled for two hours and walked the rest of the time then he'd have travelled (12 x 2) + 4 = 28 miles, so that's just a little too long. If he cycled one hour and walked two hours then he'd have done 12 + (4 x 2) = 20 miles instead.
Next you can try one-and-a-half hours, for a total journey length of (12 x 1.5) + (4x1.5) = 18 + 6 = 24 miles. Still too short, so go half-way again: 12 x (one and 3/4) + 4 x (1 and 1/4) = 21 + 5 = 26.
That works! There are clearly more mathematical solutions, but guesswork can anyway help you get into the problem and is maybe easier to have a handle on.
So anyway Jonas was walking for one-and-a-quarter hours and cycled 21 miles.