4.(10%) According to the program code shown on the right, when the input value N= 20, the output value Q=__.

Explain the relationship between Q and N.