Comments

zhoukangyang will win WTF2022!

You are given sequences of non-negative integers: $$$A=(A_1,A_2,\cdots,A_N)$$$ and $$$B=(B_1,B_2,\cdots,B_N)$$$。

At first, $$$A_i=i$$$。 You can make operations for $$$2N+1$$$

times:

Operation 1: choose $$$x$$$, for every $$$i$$$, replace $$$A_i$$$ with $$$A_i + x$$$

Operation 2: choose $$$x$$$, for every $$$i$$$, replace $$$A_i$$$ with $$$A_i \bmod x$$$

you need to make $$$A=B$$$.

C is almost the same as this problem

On gyh20IOI2023 China Team, 3 years ago
+9

xtqqwq will win IOI2023!

Why zhoukangyang is legend at CP?

UNFAIR.

On QAQAutoMatonIOI2022 China Team, 4 years ago
+108

hehezhou will win IOI2022!

On IgorIHello 2022, 4 years ago
+83

Happy new year!

Some sort of segment tree -ish thing + online queries

https://www.geeksforgeeks.org/persistent-segment-tree-set-1-introduction/

In problem D I got AC 45 and WA 5.

What's wrong?

submission

+64

Sorry for my poor English.

Let we call $$$b_i=\gcd(a_1,\cdots a_i)$$$,then we have $$$b_i|b_{i-1}$$$.

And $$$b$$$ is like $$$[c,\cdots c,d,\dots d,e,\cdots]$$$.

$$$dp_i$$$ Means the max value when you choose all $$$j$$$ That $$$i|a_j$$$.

Add some $$$i$$$ after $$$[\cdots,ki,\cdots,ki]$$$,so $$$dp_i=\max(dp_{ki}+i(t_i-t_{ki}))$$$ where $$$t_i$$$ means $$$\sum\limits_{j=1}^n[i|a_j]$$$.

Then we can solve it in $$$O(a\log a+n\sqrt a)$$$.

On ICPCNewsICPC World Finals Moscow, 5 years ago
+2

Um_nik wins!!!!!!!!!!!!!

+46

So difficult.

UPD : also fstforces.

+54

Just because he is Karry5307.

+45

math & dp round:(

$$$10^9+7,998244353,mod,mod$$$

Also fstforces.

Speedforces.

+8

[name changed]

the name before: cmii02

+8

[name changed]

the name before: cmii02

thanks.

I think my solution is not good enough.

I found that most of these AC codes got WA now.

Ah, could anybody tell me why my solution D get WA on 80? 117914897

I found some of AC codes are just like mine.

Ah, I think D is easier than C.

Maybe ABDCEF is a better choice.

Speedforces.

Many people solved ABCD.

Hope it will be rated :)

The same.

I spent 13 mins on A, but only 11 mins on B.

Maybe it will roll back soon...?

I'm here qaq

I checked it again, and I'm sure that my score is still 2360 now, but my rating decreased:(

+550 -> +549