bootfall.cpp: In function 'int main()':
bootfall.cpp:37:16: warning: iteration 1002000 invokes undefined behavior [-Waggressive-loop-optimizations]
37 | cnt[i] = 1;
| ~~~~~~~^~~
bootfall.cpp:36:23: note: within this loop
36 | for (int i = 1; i <= maxn * maxn; ++i){
| ~~^~~~~~~~~~~~~~
bootfall.cpp:46:21: warning: iteration 1002001 invokes undefined behavior [-Waggressive-loop-optimizations]
46 | if (dp[j] > 0){
| ~~~~^
bootfall.cpp:45:27: note: within this loop
45 | for (int j = 0; j <= maxn * maxn; ++j){
| ~~^~~~~~~~~~~~~~
bootfall.cpp:58:28: warning: iteration 1002000 invokes undefined behavior [-Waggressive-loop-optimizations]
58 | cnt[j] = cnt2[j];
| ~~~~~~^
bootfall.cpp:57:27: note: within this loop
57 | for (int j = 1; j <= maxn * maxn; ++j){
| ~~^~~~~~~~~~~~~~
bootfall.cpp:58:20: warning: 'void* __builtin_memcpy(void*, const void*, long unsigned int)' forming offset [8016008, 8016015] is out of the bounds [0, 8016008] of object 'cnt' with type 'long long int [1002001]' [-Warray-bounds]
58 | cnt[j] = cnt2[j];
| ~~~~~~~^~~~~~~~~
bootfall.cpp:17:31: note: 'cnt' declared here
17 | ll a[maxn], dp[maxn * maxn ], cnt[maxn * maxn], cnt2[maxn * maxn];
| ^~~
bootfall.cpp:59:21: warning: 'void* __builtin_memset(void*, int, long unsigned int)' forming offset [8016008, 8016015] is out of the bounds [0, 8016008] of object 'cnt2' with type 'long long int [1002001]' [-Warray-bounds]
59 | cnt2[j] = 0;
| ~~~~~~~~^~~
bootfall.cpp:17:49: note: 'cnt2' declared here
17 | ll a[maxn], dp[maxn * maxn ], cnt[maxn * maxn], cnt2[maxn * maxn];
| ^~~~