Problem in solving question 1829G : Hits Different

Правка en1, от godmodegod, 2024-08-21 19:46:10

Here's my attempt at solving the problem 1829G

I've started from the bottom nth row and worked my way up from there. The set considered has all the values that have already been taken before. This solution fails for the sample test case when n = 1434( gives 80385350, should give 63145186)

Code

Where am I messing up here?

Теги dp, geometry, div.4

История

 
 
 
 
Правки
 
 
  Rev. Язык Кто Когда Δ Комментарий
en2 Английский godmodegod 2024-08-21 19:46:58 238
en1 Английский godmodegod 2024-08-21 19:46:10 3163 Initial revision (published)