b = ''.join([str(i) for i in range(100)]) c = int(input()) print(b[c])