qriyadh's blog

By qriyadh, history, 10 months ago, In English

1926C - Vlad and a Sum of Sum of Digits i couldn't find optimal solution in the contest for this problem so after the contest i looked at editorial and it was actually easy. but i tried some submissions and i get TLE 2.

247790985 please look at this submission which i get tle 2

  • Vote: I like it
  • 0
  • Vote: I do not like it

»
10 months ago, # |
Rev. 2   Vote: I like it 0 Vote: I do not like it

Precompute the sum from 1 to 2e5 and then run your test cases and you will get your answer in O(1).