Answer:
Ryan takes 6n+36m -42 seconds to reach the nth flag for the mth time.
Step-by-step explanation:
It takes Ryan to run from 1st to 6th flag in 30 seconds, so it takes him
30 * 6/3 = 36 seconds to make one complete round.
or it takes 6 seconds to run from one flat to the next.
To reach the nth flag (n=1,2,3,4,5, or 6)
Ryan takes 6(n-1) seconds.
To reach it the mth times, he needs to add 36(m-1) seconds.
So time it takes Ryan to reach the nth flag for the mth time takes
6(n-1) + 36(m-1)
= 6n - 6 + 36m - 36
= 6n+36m -42 seconds