n, k = map(int, input().split()) a = '1342' * 5043 b = '1'*k + a print(b[:n])