s = 0; i=0; while(s < 5); i = i+1; s = s + 1/i; endwhile; s = 0; for j = 1:i-1; s = s + 1/j; endfor;