n=int(input())for i in range(1,n): if (i%7)!=0: print(i,end=' ') print()
20
1 2 3 4 5 6 8 9 10 11 12 13 15 16 17 18 19
The brand new service which powers Ideone!
Widget for compiling and running the source code in a web browser!