n = int(input()) if n == 1: print(1) else: d = list(range(n)) s = "" for _ in range(n): for e in d: s += str(e) print(s[::-1])