Vanya got an important task — he should enumerate books in the library and label each book with its number. Each of the *n* books should be assigned with a number from 1 to *n*. Naturally, distinct books should be assigned distinct numbers.

Vanya wants to know how many digits he will have to write down as he labels the books.
The first line contains integer *n* (1 ≤ *n* ≤ 10<sup class="upper-index">9</sup>) — the number of books in the library.

n=input()
nl=len(n)
n=int(n)
if nl==1:
    print(n)
elif nl==2:
    print(2*n-9)
else:
    s=189
    ten=100
    nine=900
    nl=nl-3
    a=0
    for i in range(nl):
        print(nine*(i+3))
        s+=(nine*(i+3))
        nine*=10
        ten*=10
        a=i+1
        print(i)
    print(a)
    n=n-ten+1
    a=a+3
    s+=n*a
    print(s)



