4 of 5 deleted 4 characters in body

# JavaScript (ES6) 44 74

S=n=>(n-~(n+'').replace(/./g,8)+'').slice(1)


Test in FireFox console

;[0,1,10,11,42,100,800,1060,10270,100501]
.forEach(x => console.log(x +" -> '" + S(x) + "'"))


Output

0 -> ''
1 -> '0'
10 -> '9'
11 -> '00'
42 -> '31'
100 -> '89'
800 -> '689'
1060 -> '949'
10270 -> '9159'
100501 -> '89390'


How did I think of this?

Given a fixed number of digits, the output sequence is simply ascending, so there a fixed delta between input and output. Have a look:

  1..10 -> 0..9 (delta -1)
11..110 -> 00..99 (delta -11)
111..1110 -> 000..999 (delta -111) mmm there's pattern here...


But the leading 0s are difficult to manage, so I have a standard trick, add a first digit and work modulo (that is, cut the first digit in output). Then -1-> +9, -11 -> +89, -111 -> +889 and so on.
Last step: I don't care what the first digit is, so there is no need to check if the iinput number is < or > than 111... (honestly I found this by trial and error)