N = int(input())
alp = [chr(i) for i in range(97, 97+26)]
for i in range(N):
    if i!=0:
        start = int('1'+'0'*(i-1))
        end = int(''.join([str(j) for j in range(1,i+1)]))
        for m in range(start, end+1):
            ids = [0]*(N-i)
            ids.extend([int(o) for o in str(m)])
            print(''.join([alp[one] for one in ids]))
    else:
        print('a'*N)