Given a non-negative integer n and a digit d (0 to 9), count how many times the digit d appears in the decimal representations of all integers from 0 to n inclusive. The number 0 is written as '0'.
You've read your 3 free write-ups
Sign up free to keep reading. Your account opens the first 10 questions of every company.