N = int(input()) print('0', end='') for i in range(N): if i == 0: print('.', end='') print('142857'[i%6], end='') print()