N = int(input())
# 97~122
# 0~25


def chrs(X):
    r = ""
    for x in X:
        r += chr(int(x)+97)
    return r


def inv(X):
    R = ""
    for x in X:
        if x == "0":
            R += "1"
        elif x == "1":
            R += "0"
    return R


Xs = []
for i in range(2 ** N):
    X = bin(i)[2:]
    if len(X) < N:
        X = "0" * (N - len(X)) + X
    if inv(X) in Xs:
        pass
    else:
        Xs.append(X)
for X in Xs:
    print(chrs(X))