hiho week 180 register

Ended

Participants:184

Verdict:Accepted
Score:100 / 100
Submitted:2017-12-10 13:16:34

Lang:Python2

Edit
1
2
3
4
5
6
7
8
9
10
11
n = int(input())
xy = 19
while n > x * y:
    n -= x * y
    x += 1
    y *= 10
a = (n - 1) // x
a += 10 ** (x - 1)
b = (n - 1) % x
print str(a)[b]
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX