There's a few ways to do this. One way is to convert the hours to minutes: 1/3 of an hour is 20 mins, so 2/3 is 40 mins. 2 hrs is 2*60=120 mins. Add this to 40 mins=160 mins. Now divide by 5: 32 mins. So John spends 32 minutes of the 2 2/3 hrs lifting weights.
Another way is to work out a fifth of an hour=60/5=12 mins. A fifth of 2 hrs is twice this: 24 mins. A fifth of 40 mins is 8 mins, added to 24 gives 32 mins.
Another way is to stick with fractions. Convert 2 2/3 hrs to an improper fraction: 8/3 hrs (numerator is 3*2+2=8 and denominator is the same as the fraction. There are 3 thirds in 1 so there are twice as many in 2, plus the 2 in 2/3.). We multiply 8/3 by a fifth, which is the same as dividing by 5: 8/(3*5)=8/15 hrs =8*60/15 mins=8*4=32mins.
Take your pick!