count = 0 cand = 3 while(count<6): for num in range(2,cand): print cand, '%', num if cand%num==0: cand=cand+2 else: count=count+1 cand=cand+2 print count,cand
Standard input is empty
3 % 2 1 5 5 % 2 2 7 7 % 3 3 9 9 % 4 4 11 11 % 2 5 13 13 % 3 6 15 15 % 4 7 17 17 % 5 8 19 19 % 6 9 21 21 % 7 23 % 8 10 25 25 % 9 11 27 27 % 10 12 29