a = "".join(map(str,range(101))) print(a[int(input())-1])