Codeforces Round 952(DIV 4) doubt, Problem G

Revision en1, by ayushanshul07, 2024-06-15 06:53:32

1985G - D-Function

For numbers with l+1 digits, there are floor(9/k) (say a) options per digit, hence the total number of numbers should be a^(l+1). Similarly, for l+2 digits, a^(l+2). So on for r digits, a^(r).

Shouldn't the answer be the sum of these numbers?

a^(l+1) + a^(l+2) + .... + a^r

Tags div4, maths

History

 
 
 
 
Revisions
 
 
  Rev. Lang. By When Δ Comment
en2 English ayushanshul07 2024-06-15 07:04:55 4 Tiny change: 'loor(9/k) (say a) o' -> 'loor(9/k) + 1 (say a) o'
en1 English ayushanshul07 2024-06-15 06:53:32 347 Initial revision (published)