Today due to a power outage there may be disruptions in the work of Codeforces and Polygon. Please do not plan any important events during this time. If there are details or the exact time, we will definitely publish them. Estimated time of maintenance: from 3 Aug, 14:30 (UTC) to 3 Aug, 18:00 (UTC).
×

# | User | Rating |
---|---|---|

1 | tourist | 3819 |

2 | Benq | 3745 |

3 | ksun48 | 3560 |

4 | Radewoosh | 3511 |

5 | Um_nik | 3489 |

6 | peehs_moorhsum | 3460 |

7 | Petr | 3414 |

8 | Miracle03 | 3410 |

9 | maroonrk | 3400 |

10 | sunset | 3338 |

# | User | Contrib. |
---|---|---|

1 | 1-gon | 208 |

2 | awoo | 182 |

3 | Errichto | 180 |

4 | Um_nik | 179 |

5 | -is-this-fft- | 174 |

5 | maroonrk | 174 |

7 | Radewoosh | 172 |

7 | tourist | 172 |

9 | SecondThread | 170 |

10 | rng_58 | 166 |

You can use several words in query to find by all of them at the same time. In addition, if you are lucky search understands word forms and some synonyms. It supports search by title and author. Examples:

`305`

— search for 305, most probably it will find blogs about the Round 305`andrew stankevich contests`

— search for words "andrew", "stankevich" and "contests" at the same time`user:mikemirzayanov title:testlib`

— search containing "testlib" in title by MikeMirzayanov`"vk cup"`

— use quotes to find phrase as is`title:educational`

— search in title

1.

Hello 2018 Hello 2018!
If you're still thinking what to do on the eighth day of year 2018, pay attention! The first round for both divisions of the new year starts on January 8 at 17:35 Moscow time ([what about other timezones?](https://www.timeanddate.com/worldclock/fixedtime.html?msg=Hello+2018&iso=20180108T1735&p1=3396&ah=2&am=30)).
Four important components of Hello 2018 will be the same as in Good Bye 2017:
- Div1 + Div2 combined
- 8 problems
- 2 hours 30 minutes
- Rated
But there will also be a substantial difference:
- Different problems
The problems of this round have been proposed and prepared by [user:YakutovDmitriy,2018-01-06], [user:BudAlNik,2018-01-06] and myself.
Thanks to everyone without whom this round wouldn't be possible as well: [user:AlexFetisov,2018-01-06], [user:Golovanov399,2018-01-08], [user:KAN,2018-01-06], [user:MikeMirzayanov,2018-01-06], [user:PavelKunyavskiy,2018-01-06], [user:qwerty787788,2018-01-06], [user:VArtem,2018-01-07], [user:winger,20...

! The first round for both divisions of the new year starts on January 8 at
17:35 Moscow time ([what, If you're still thinking what to do on the eighth day of year 2018, pay
attention! Thefirst round

Announcement of Hello 2018

2.

About Division 4 Rounds Hello Codeforces!
Initially, here was an announcement of the first round for the fourth division. But currently, in comments there is the huge discussion of division 4 rounds in general. Honestly, I read all (almost all) comments.
I decided to replace the text of this post to match the comments better. Also, I'll write one more post separately to discuss problems. And this post will be about division 4 rounds in general.
About Div4 rounds:
* I'm not afraid of a queue or servers overload: it is technical challenges and my task is to resolve them. The previous biggest rounds were not overshadowed by technical problems and judging delays, they went well. I see no reasons why something should work much worse in the rounds for Div. 4 (and if it does, then this should be fixed).
* I don't think that Div. 3 rounds are too dificult. Actually, they are quite good for beginners. They are noticeably easier than Div. 2. Almost every round trusted participants solve all problems, ma...

About Division 4 Rounds, Hello Codeforces! Initially, here was an announcement of the first round for
the fourthdivision, Initially, here was an announcement of the first round for the fourth division.
But currently

3.

Codeforces Round #635 _Riichi...Tsumo! 2 han 2000 points!_
![ ](/predownloaded/a9/4f/a94f898a1c9c906cd81ecd483c3ec9ff5e6315c0.png)
Hi! Have you ever heard of the game called _Mahjong Soul_? It is a Japanese Mahjong game that is famous for the adorable characters.
We are excited to invite you to take part in [Codeforces Round #635](https://codeforces.com/contests/1336,1337), where you can help the characters in trouble. This round will be held on [contest_time:1336]. Most importantly, it is **rated** for both divisions!
Each division will be given **6 problems** and you will have **2.5 hours** to solve them. An interactive problem may be found in this round. If you are not familiar with interactive problems, you can learn about them [here](https://codeforces.com/blog/entry/45307).
The problems were prepared by [user:EternalAlexander,2020-04-14], [user:ustze,2020-04-14] and me [user:Sooke,2020-04-14].
We sincerely thank [user:isaf27,2020-04-14] for reviewing and coordinating the round, and ...

** for both divisions! Each division will be given **6 problems** and you will
have **2.5 hours** to solve

Announcement of Codeforces Round #635 (Div. 1)

Announcement of Codeforces Round #635 (Div. 2)

4.

Codeforces Round #589 (Div. 2) **다시 만나서 반가워요, 코드포스!** (Nice to see you again, Codeforces!)
I'm again happy to introduce you to [Codeforces Round #589 (Div. 2)](https://codeforces.com/contests/1228). Please look at following information for details:
- This contest will take place on [contest_time:1228].
- The round will be **rated for all Division 2 participants**.
- There are **6 problems** and you will have **2 hours** to solve them. Score distribution will be announced later.
The listed handles below are contributors. Thank you for all who listed!
- **Main author**: ~McDic,2019-09-26 — I made and prepared all problems.
- **Coordinator**: ~arsijo,2019-09-26 — He is my coordinator again.
- **Early phase testers**: ~dorijanlendvaj,2019-09-26 ~tfg,2019-09-26 ~Lawali,2019-09-26 — They are early phase testers. They mostly focused on test data.
- **Late phase testers**: ~_Kuroni_,2019-09-26 ~imbr92,2019-09-26 ~Redux,2019-09-26 ~Dr_Park,2019-09-26 ~Mahotsukai,2019-09-26 ~TOPWINDFLOWER,20...

will be **rated for all Division 2 participants**. - There are **6 problems**
and you will have **2 hours

Announcement of Codeforces Round #589 (Div. 2)

5.

Codeforces Round #649 (Div.2) Hi everyone!
Codeforces round #649 will take place on [contest_time:1364]. It's rated for the second division, but, as usual, first division participants can take part out of competition.
The problems were created by me. I'd like to thank my forever orzable coordinator [user:antontrygubO_o,2020-06-11]; my incredible army of testers [user:dorijanlendvaj,2020-06-11], [user:300iq,2020-06-11], [user:Osama_Alkhodairy,2020-06-11], [user:AmShZ,2020-06-11], [user:Taran_1407,2020-06-11], [user:TigranMec,2020-06-11], [user:_Aaryan_,2020-06-11], [user:Mohammad_Yasser,2020-06-11], [user:zoooma13,2020-06-11], [user:lavish315,2020-06-11], [user:Utkarsh.25dec,2020-06-11], [user:NOOBxCODER,2020-06-11], and [user:Laggy,2020-06-11]; and, of course, you-know-who for the amazing codeforces and polygon platforms.
This time, in an effort to kill type-races and because I'm lazy, you'll be given 5 problems and 2 hours to solve them.
**UPD:** the scoring distribution will be 750-1000-1500-2000-2500...

for the second division, but, as usual, first division participants can take
part out of competition, , but, as usual, first division participants can take part out of competition.

Announcement of Codeforces Round #649 (Div. 2)

6.

Linear Recurrence and Berlekamp-Massey Algorithm **#IjustWantContribution**
It seems there isn't any blog about Berlekamp-Massey Algorithm around here, so I decided to go on a try. :P
Acknowledgement: Hats off to matthew99 for introducing this algorithm.
#### What is 'linear recurrence'?
Assuming there is a (probably infinity) sequence $a_0,a_1...a_{n-1}$, we call this sequence satisfies a linear recurrence relation $p_1,p_2...p_m$, iff $\forall i \geq m,~a_i=\sum_{j=1}^m a_{i-j}p_j$. (Obviously, if $m\geq n$ any $p$ can do :P)
#### How to calculate k-th term of a linear recurrence?
For a polynomial $f(x)=\sum_{i=0}^{t} c_ix^i$, we define $G(f)=\sum_{i=0}^{t} c_ia_i$.
Obviously $G$ satisfies $G(f)\pm G(g) =G(f \pm g)$.
Because $a_i=\sum_{j=1}^m a_{i-j}p_j$, if we let $f(x)=x^m-\sum_{j=1}^m x^{m-j}p_j$, then $G(f)=0$. Also $G(fx),G(fx^2)...=0$. So $G(fg)=0$ (g is any polynomial).
What we want is $G(x^k)$. Because $G(f\lfloor x^k/f\rfloor)=0$, then $G(x^k)=G(x^k \bmod f)$.
[cut]
We can calculate $x^k \b...

) at positions $first non

7.

Codeforces Round #732 Hello, Codeforces!
I'm glad to invite you to [contest:1545] and [contest:1546], which will be held on [contest_time:1545]. **Note the unusual start time of the round.**
The round will be rated for both divisions. Each division will have **6 problems** and **2.5 hours** to solve them. There may or may not be an interactive problem, so I suggest you should read the [guide for interactive problems](https://codeforces.com/blog/entry/45307).
All problems were written and prepared by [user:CoupDeGrace,2021-07-02], [user:kuangbin,2021-07-02], [user:mejiamejia,2021-07-02], [user:Heltion,2021-07-02], [user:Melacau,2021-07-02], [user:Nanako,2021-07-02], [user:GOATWU,2021-07-02], [user:Cirno_9baka,2021-07-02], [user:Suiseiseki,2021-07-02], [user:ODT,2021-07-02], [user:box,2021-07-03], [user:Ynoi,2021-07-02], [user:syh0313,2021-07-02], [user:wh0816,2021-07-02] and me.
And thanks to [user:QAQAutoMaton,2021-07-02], [user:gamegame,2021-07-02], [user:starusc,2021-07-02], [user:interesting...

for both divisions. Each division will have **6 problems** and **2.5 hours**
to solve them

Announcement of Codeforces Round #732 (Div. 1)

Announcement of Codeforces Round #732 (Div. 2)

8.

Codeforces Round #703 (Div. 2) Hi, Codeforces!
I finally get to return something to this great community, so I am glad to invite you to take part in [Codeforces Round #703 (Div. 2)](https://codeforces.com/contest/1486), which will take place on [contest_time:1486]. The round will be **rated for the participants with rating lower than 2100**. Participants from the first division are also welcomed to take part out of competition.
You will be given **2 hours 15 minutes** to solve **6 problems**. All the problems were created and prepared by me. One of the problems is interactive, please read [the guide of interactive problems](https://codeforces.com/blog/entry/45307) before the contest.
I would also like to thank:
<ul>
<li> [user:antontrygubO_o,2021-02-16] for excellent coordination! </li>
<li> [user:1-gon,2021-02-16], [user:3EVEHAR_KOAVA,2021-02-16], [user:Akulyat,2021-02-16], [user:Aleks5d,2021-02-16], [user:BRCode,2021-02-16], [user:Osama_Alkhodairy,2021-02-16], [user:PO3OBAR_Bblnb,2021-02-16], [user:...

lower than 2100**. Participants from the first division are also welcomed to
take part out, **. Participants from the first division are also welcomed to take part out of
competition.

Announcement of Codeforces Round #703 (Div. 2)

9.

Codeforces Raif Round 1 [Div. 1 + Div. 2] Hello, Codeforces!
Welcome to the [contest:1428] supported by Raiffeisenbank, that will start on [contest_time:1428]. **It will be a combined rated round for both divisions. Note that the start time is unusual.**
All problems were authored and prepared by [user:bensonlzl,2020-10-15], [user:oolimry,2020-10-15], [user:errorgorn,2020-10-15], [user:dvdg6566,2020-10-15], [user:shenxy13,2020-10-15].
[user:Ari,2020-10-15] gato to:
- [user:isaf27,2019-05-10] and [user:KAN,2020-10-15] for round coordination and help with preparation
- [user:zhangguangxuan99,2020-10-15] for being epic IOI trainer <3
- Our army of testers: [user:Ari,2020-10-15], [user:KAN,2020-10-15], [user:Monogon,2020-10-15], [user:Prabowo,2020-10-15], [user:SYY,2020-10-15], [user:SleepyShashwat,2020-10-15], [user:TeaTime,2020-10-15], [user:Tlatoani,2020-10-15], [user:_rs_,2020-10-15], [user:agul,2020-10-15], [user:cstuart,2020-10-15], [user:dantoh,2020-10-15], [user:jhkoh,2020-10-15], [user:kai824,2020-10-15]...

://codeforces.com/blog/entry/83771) **UPD 3: First ACs and winners** *First
ACs* A: [user

Announcement of Codeforces Raif Round 1 (Div. 1 + Div. 2)

10.

Codeforces Round #736 Hello, Westeros!
I'm glad to invite you to [contest:1548] and [contest:1549], which will be held on [contest_time:1548].
The round will be rated for both divisions. Each division will have 5-7 problems and 2 hours and 15 minutes to solve them. There **will not** be an interactive problem, so yay!!!
This round would not have been possible without the following individuals:
1. [user:Aleks5d,2021-07-30], for awesome coordination of my round.
2. [user:Benq,2021-07-30], for extensive testing and contributions throughout the round, especially for problem G.
3. [user:1-gon,2021-07-30], for discussing problems and statements with me for hours on Discord.
4. [user:amgfrthsp,2021-08-01], for translating statements into Russian.
5. [user:MikeMirzayanov,2021-08-01], for Codeforces and Polygon.
#### 32 testers
The round had a total of 32 testers. I tried to get a "rainbow" of testers to help guarantee a most balanced round. Thank to you to each and every one of them!
- [user:...

on [contest_time:1548]. The round will be rated for both divisions. Each
division will have 5-7

Announcement of Codeforces Round #736 (Div. 1)

Announcement of Codeforces Round #736 (Div. 2)

11.

'/' or '//' division — python3 Hello Codeforces community!!
This is my first post on codeforces. I am not a regular writer who would post ideas or things because the things i used to find out seemed trivial(This post may seem trivial to many of you :D) to me earlier. But not until 2 days ago when i encountered a kind of mistake in my code. I hope this post help other python3 users or those trying to make a shift to python3.
**What happened:** I got wrong answer for Problem A [979A](http://codeforces.com/contest/979/problem/A) . As a normal user i checked, rechecked my logic for it. Read editorial also, it matched my logic too. Looked into [test case](http://codeforces.com/contest/979/submission/38222153) that made it fail.
**My Code**
~~~~~
n = int(input())
if n != 0:
if (n+1)%2:
print(n+1)
else:
print(int((n+1)/2))
else:
print(0)
~~~~~
Seems the logic is correct so, why it is failing for test case 11. Researched a lot on topics i didn't understood before. Thanks to ~PikMike,2018-...

'/' or '//' division — python3, reading from various sources as listed below: - First of all, '/' is floating
pointdivision, - First of all, '/' is floating point division in python3 by default. So, when
we use, Input: n = 822981260158260519 Now , (n+1)/2 would first convert n+1 as float, This is my first post on codeforces. I am not a regular writer who would post
ideas or things

12.

The Second Revolution of Colors and Titles Over the last several months the Codeforces team has been looking anxiously at the inflation in the rating caused by both an influx of new users and the imperfect calculating formulas.
In the end it lead to noticeable shifts in colors and titles. For example, getting red in 2015 became much easier than in 2013.
We conducted a [survey about the way to introduce the color bounds](/blog/entry/20629). We are happy to announce the updated colors and titles!
A summary of the main changes goes like that:
* a new color: greenish-blue color or cyan — just like the name implies, this color takes its place between green and blue, now the participants of the second division will be better differentiated;
* all the colors shift upwards along the rating scale — see the table below. Now reaching the top positions will be harder;
* the legendary grandmaster — the new title and color for those who reached the sky high rating 2900.
The cold colors (gray, green, cyan an...

and blue) still correspond to the second division and the other ones
correspond to thefirst one, by the participants from the first division., >Title Division, The cold colors (gray, green, cyan and blue) still correspond to the second
division and the other

13.

Cheating in Educational Codeforces Round (92) Division 2 I noticed four users who have cheated in this Round (Educational Codeforces Round 92) and I want to name them here. I request the Codeforces community to take strict action against them those who degrade the quality of this beautiful platform. With internship season round the corner, Codeforces is often taken as an accountable platform by Companies and these people should be punished.
Their handles are: [user:interview,2020-07-29] , [user:_krtky_,2020-07-29] ,[user:rahul16077,2020-07-29] [user:tempcfcfcf,2020-07-29]
The first observation was the time at which the three users submitted their solutions. All of them submit solutions at almost the same time, thinking it wouldn't be noticed. I attach here a snippet. This is so disgusting.
My proofs don't end here. Look at their submissions. They use very tactful tricks to avoid plagiarism checks, and I request the community here to take strict action on them. Please ban their accounts permanently. Their code snippets are almost ...

Cheating in Educational Codeforces Round (92) Division 2, The first observation was the time at which the three users submitted their
solutions. All of them, ] [user:tempcfcfcf,2020-07-29] The first observation was the time at which the
three users

14.

New: Educational Rounds on Codeforces! Hi everybody!
First, I invite you to take part in an official [contest:597]. The fact is, the Codeforces team has made numerous changes to the platform (details are below), and we want to be sure that the basic functionality remained unchanged. This round will have a shortened duration of 1.5 hours, consist of 3 (maybe 4) problems that you might have already seen before. Its purpose is to test the system on the one hand, and on the other hand — to brighten up a Wednesday evening. Of course, the round will be unrated.
Now the main thing. This coming Friday (yes, the 13th of November) Codeforces starts another line of rounds. We called them Educational Rounds. Using my students at the Saratov State University Programmings Competitions Training Center as an example, I regularly notice that even those who have a considerable progress in the results on the rounds often have narrow purview in terms of standard topics and ideas, they are not familiar with many well-known problems ...

Hi everybody! First, I invite you to take part in an official [contest:597].
The fact

15.

Good Bye 2014 Hi, Codeforces!
Welcome to the last Codeforces Round of 2014, **Good Bye 2014**! This round is *very unusual*; First, the round starts at **[December 30th, 18:00 MSK](http://www.timeanddate.com/worldclock/fixedtime.html?msg=Good+Bye+2014&iso=20141230T18&p1=166&ah=2&am=30)**. Second, the round lasts for **2.5 hours**. And lastly, the round will be **division combined**, which means Div1 contestants and Div2 contestants won't be separated.
The problems are prepared by me ([user:tncks0121,2014-12-29]) and Seunghyun Jo ([user:ainta,2014-12-29]). This is our second round at Codeforces. Because our first round caused(?) [the Black Day](http://codeforces.com/blog/entry/10683), we hope this round won't cause any errors like before :D
Thanks to Won-seok Yoo([user:ainu7,2014-12-29]), who tested our round and gave us comments about the problemset.
We'd like to thank some people who were necessary to make this round: Maxim Akhmedov ([user:Zlobober,2014-12-29]) gave us great help prepar...

is *very unusual*; First, the round starts at **[December 30th, 18:00
MSK](http://www.timeanddate.com, *; First, the round starts at **[December 30th, 18:00
MSK](http://www.timeanddate.com/worldclock

Announcement of Good Bye 2014

16.

Codeforces Round #716 (Div.2) Hi everyone!
Codeforces round #716 will take place on [contest_time:1514]. It's rated for the second division, but, as usual, first division participants can take part out of competition.
The problems are based on the Egyptian IOI qualification, and they were created by me and [user:mahmoudbadawy,2021-04-17]. I'd like to thank:
- [user:KAN,2021-04-17] and [user:Nebuchadnezzar,2021-04-17] for their excellent coordination.
- [user:antontrygubO_o,2021-04-17] for improving a problem, then rejecting all our problems without reading them, then testing the round.
- [user:Yousef_Salama,2021-04-17], [user:Mohammad_Yasser,2021-04-17], [user:Noureldin,2021-04-17], and [user:Commando_,2021-04-17] for testing the official contest.
- [user:74TrAkToR,2021-04-17] and [user:psevdoinsaf,2021-04-17] for testing the round.
- [user:MikeMirzayanov,2021-04-17] for the great codeforces and polygon platforms.
This may be the most and only balanced round I've ever set. You'll be given 5 problems...

for the second division, but, as usual, first division participants can take
part out of competition, , but, as usual, first division participants can take part out of competition.

Announcement of Codeforces Round #716 (Div. 2)

17.

Divisions in AtCoder We are planning to introduce a division system to AtCoder in the near future.
Here are our current plans (but this is tentative, we may change it based on your feedback):
- The division cutoff is 2000. I think this is about the same as CF's 1900.
- We'll hold div2 contests (called ABC) every week. Usually, 100 minutes and 5 tasks: 100, 200, 300, 400-500, 600-700. Rated for 0-2000.
- Sometimes we'll hold div1 contests. There are two types of div1 contest: AGC and ARC. The first two tasks are shared with div2.
- ARC: Usually 100 minutes and 4 tasks: 400-500, 600-700, 800-900, 1000-1200. Rated for 2000-2800.
- AGC: Similar to current AGC. Rated for 2000-inf.
One major problem is that even strong people have to spend a few matches in Div2. Two "red performance" is good enough to reach Div1. Is it fine?
![Supplementary data](https://img.atcoder.jp/file/b2e31f0951831f797a3413429e97c7ec.png)
For example, it says that a gray coder solves a 200-point problem with prob...

- Sometimes we'll hold div1 contests. There are two types of div1 contest: AGC
and ARC. Thefirst, We are planning to introduce a division system to AtCoder in the near future.
Here are our

18.

Moscow Workshops Juniors 2021: first qualifying pre-New Year round! ![ ](/predownloaded/b0/92/b092c140bdb1a1d8efeee4a1f5fdea8518b5d254.png)
We welcome high school students to take part in the programming boot camp **Moscow Workshops Juniors** that will be held on **February 24 – March 5** by Moscow Institute of Physics and Technology. The first qualifying online round (out of 3 or 4) will be open on **December 27 at 12:00** pm UTC+03.
Moscow Workshops Juniors is the unique boot camp where students will be preparing for the **national competitions and international olympiads in informatics**. According to the statistics, 17 graduates of MWJ 2020 took part in the IOI and 11 of them won medals.
Two years ago we started an **English-speaking group** at Moscow Workshops Juniors for students from Armenia, Azerbaijan, Bosnia and Herzegovina, Denmark, India, Italy, Syria, and Turkey. Last year guys from Netherlands and Romania also came to Russia. In total about 170 students participate in the boot camp every year. We would be glad to see everyone ag...

Moscow Workshops Juniors 2021: first qualifying pre-New Year round!, on **February 24 – March 5** by Moscow Institute of Physics and Technology. The
first qualifying online

19.

Codeforces Round #134 Добро пожаловать на Codeforces Round #134!
После более чем двух лет, я снова с большим удовольствием выступаю в качестве автора контеста на Codeforces. Большое спасибо [user:Gerald,2012-08-17] за помощь по подготовке контеста.
Я надеюсь, что вы получите удовольствие от решения задач ничуть не меньшее, чем получили мы,
пока готовили эти задачи для Вас.
В этом раунде будет использована динамическая система оценки задач, при этом задачи будут расположены в порядке их предполагаемой сложности.
Верны ли наши предположения? Посмотрим. :-)
Всем удачи!
P.S. Данный пост является переводом оригинального поста на английском языке. Комментарии на английском приветствуются.
**Update:** Контест закончился! Результаты:
**First division:**
1. [user:rng_58,2012-08-18]
2. [user:panyuchao,2012-08-18]
[user:pieguy,2012-08-18]
4. [user:tourist,2012-08-18]
5. [user:Petr,2012-08-18]
6. [user:ACRush,2012-08-18]
7. [user:Zhukov_Dmitry,2012-08-18]
Все участники...

**First division:**, ; it was also present in the first division as problem C, and proved tricky
even for the experienced

Announcement of Codeforces Round #134 (Div. 1)

Announcement of Codeforces Round #134 (Div. 2)

20.

Codeforces Round #717 (Div.2) It's me again!
Codeforces round #717 will take place on [contest_time:1516], an hour early than the usual timing. It's rated for the second division, but, as usual, first division participants can take part out of competition.
The problems were created by me, and some of them are based on the Egyptian IOI qualification. I'd like to thank:
- [user:KAN,2021-04-19] and [user:Aleks5d,2021-04-19] for their excellent coordination.
- [user:Akulyat,2021-04-19], [user:__cucumber__,2021-04-19], [user:Randle,2021-04-19], [user:Riladavin,2021-04-19], [user:Waley,2021-04-19], [user:MForest,2021-04-19], [user:_Stefan_,2021-04-19], [user:RabbitPower,2021-04-19], and the official contestants, I guess, for testing the round.
- [user:MikeMirzayanov,2021-04-19] for the great Codeforces and Polygon platforms.
You'll be given 5 problems, but this time you'll have 2 hours to solve them.
**UPD:** the scoring distribution will be 500-1000-1500-2000-2750.
**UPD:** [the editorial.](https://c...

the usual timing. It's rated for the second division, but, as usual, first
division participants can, . It's rated for the second division, but, as usual, first division
participants can take part out

Announcement of Codeforces Round #717 (Div. 2)

21.

[Tutorial] Generating Functions in Competitive Programming (Part 1) Hi everyone! Inspired by the recent [Codeforces Round 641](https://codeforces.com/contest/1349), I decided to write an introductory tutorial on generating functions here. I am by no means an expert in generating functions so I will write about what I currently know about them. [user:MiFaFaOvO,2020-05-15] has written a really interesting [blog](https://codeforces.com/blog/entry/76447) here on Codeforces about more advanced applications of generating functions, but I think there is no English tutorial on the basics of this topic yet (or at least on CP sites). Thus, I would like to share about this topic here.
I plan to split this tutorial into two parts. The first part (this post) will be an introduction to generating functions for those who have never learned about them at all, and some standard examples and showcases of generating functions. The second part will be a collection of several applications of generating functions in CP-style problems. If you are already familiar with ge...

this topic here. I plan to split this tutorial into two parts. The first part
(this post

22.

Codeforces Round #551 (Div. 2) Hi Codeforces!
We are glad to invite you to our first Codeforces Round [contest:1153] which will be held on [contest_time:1153]. This round will be rated for participants with rating less than 2100. We will be glad to see participants from the first division to join out of competition as well!
In this round, as the best friend of Serval's, you are going to help him to solve the problems he meets.
The problems are prepared by [user:bzh,2019-04-12] and me. We hope you will enjoy the round. :P
Great thanks to [user:300iq,2019-04-12] for coordination of this round, [user:isaf27,2019-04-12], [user:gritukan,2019-04-12], [user:KAN,2019-04-12], [user:mohammedehab2002,2019-04-12], [user:learner99,2019-04-12], [user:aleks5d,2019-04-12] and [user:Um_nik,2019-04-13] for testing our rounds, and [user:MikeMirzayanov,2019-04-12] for the amazing Codeforces and Polygon platforms.
You will be given 6 problems to solve in 2 hours. Scoring distribution will be announced later.
Please ...

2100. We will be glad to see participants from the first division to join out
of competition as well, to see participants from the first division to join out of competition as well!

Announcement of Codeforces Round #551 (Div. 2)

23.

Codeforces Round #487 (Div. 2) Here and there, summer's in the air! (I beg your forgiveness, residents of the Southern Hemisphere... > <)
I'm delighted to invite you to [contest:989], which starts at [contest_time:989]. Please note that the timing is, as usual, unusual.
This is my third time creating a contest from scratch. Along the way can be seen the efforts of: [user:KAN,2018-06-10] the super-ultra-hyper-mega-meta coordinator, who has reviewed, refined and translated the problems; [user:300iq,2018-06-10], [user:Livace,2018-06-10], [user:mike_live,2018-06-10], [user:Noam527,2018-06-10], [user:RobeZH,2018-06-10], and [user:Tommyr7,2018-06-11] the super-ultra-great-delicious-wonderful testers, that have populated our collection of solutions; and [user:MikeMirzayanov,2018-06-10] along with the super-ultra-extreme-awesomazing Codeforces/Polygon team, who have made all these happen in the way it is! Kudos to all of you!
The round will be **rated** for contestants from the second division, and the first divisi...

of you! The round will be **rated** for contestants from the second division,
and thefirst, ,2018-06-11] (First to solve E!) 4. [user:kobae964,2018-06-11] (_That_ close!
Integerdivision, The round will be **rated** for contestants from the second division, and the
first division

Announcement of Codeforces Round #487 (Div. 2)

24.

Codeforces Round #542 Hey Codeforces!
We’re thrilled to invite you guys to Codeforces Round #542, which is going to take place on [Sunday, February 24, 2019, at 18:35 MSK](https://www.timeanddate.com/worldclock/fixedtime.html?day=24&month=2&year=2019&hour=18&min=35&sec=0&p1=166). There will be a separate round for each division, and they will be rated!
Problems were prepared by [user:MikeMirzayanov,2019-02-24], [user:zoomswk,2019-02-23] and me. As the round authors, we would like to thank [user:ksun48,2019-02-23], [user:isaf27,2019-02-23], [user:tuna_salad,2019-02-23], and [user:Um_nik,2019-02-23] for testing the problems; [user:300iq,2019-02-23] and [user:KAN,2019-02-23] for their help and advice in contest preparation; and the invisible [user:MikeMirzayanov,2019-02-23] for the incredible Codeforces and Polygon platforms.
Each division will be given 6 tasks and 2 hours to solve them. As per the Codeforces tradition, scoring distributions will be revealed shortly before the round.
We wish you th...

A of the first division will have subtasks like the way task D of the second
division round do. Div2: 500, Each division will be given 5 tasks. Also, task A of the first division will
have subtasks like

Announcement of Codeforces Round #542 [Alex Lopashev Thanks-Round] (Div. 1)

Announcement of Codeforces Round #542 [Alex Lopashev Thanks-Round] (Div. 2)

25.

Logarithmic division in C++ error? I was dividing using the log function in C++ today when I came across an error that I couldn't find an answer for online.
Given an integer n, I wanted to find the floor of log n base 10.
It worked for most numbers besides for some powers of 10. I decided to test increasing powers of 10 from 10^1 to 10^6. I first casted the double results as integers but 10^3 and 10^6 did not give the proper output. Using the floor function on the doubles also gave the same results. I then printed the double results which corrected it, but this won't work for non-perfect powers of 10. I'm a bit confused because I heard that division and multiplication are floating-point error safe.
My code:
~~~~~
int a[6]={10,100,1000,10000,100000,1000000};
for (int i=0;i<6;i++){
int x=(int)(log(a[i])/log(10));
double y=log(a[i])/log(10);
cout << x << " " << y << " ";
}
~~~~~
Output:
1 1
2 2
2 3
4 4
5 5
5 6
Does anyone know why this happens and how I can p...

Logarithmic division in C++ error?, 10^1 to 10^6. I first casted the double results as integers but 10^3 and 10^6
did not give, from 10^1 to 10^6. I first casted the double results as integers but 10^3 and
10^6 did not give

26.

Codeforces Round #468 and Technocup 2018 Final Round Hello everybody!
Today, on March 4th 2018 the final round of Technocup olympiad for Russian-speaking high school students is held. The round starts at 11:30 Moscow time.
After the round starts, you can watch the [current results](/contest/944/standings).
For those who want to compete on the same problems, we will host two Codeforces rounds: one for the first, and one for the second division. The rounds will start at [15:35 UTC](https://www.timeanddate.com/worldclock/fixedtime.html?msg=Codeforces+Round+%23468&iso=20180304T1835&p1=166&ah=2), don't miss them!
**If you compete in the Final Round today, you can't compete in the rounds at evening.**
The problems are prepared by [user:Endagorion,2018-03-04], [user:komendart,2018-03-04], [user:syncopate,2018-03-04], [user:AndreySergunin,2018-03-04], [user:fcspartakm,2018-03-04], [user:MikeMirzayanov,2018-03-04] and me. For testing the problems many thanks to [user:demon1999,2018-03-04], [user:Belonogov,2018-03-04], [user:grituka...

for the first, and one for the second division. The rounds will start at
[15:35 UTC](https, First division:

Announcement of Технокубок 2018 - Финал (только для онсайт-финалистов)

27.

Help required with CSES problem "Apple Division" [The problem](https://cses.fi/problemset/task/1623/)
I am trying out the following approach:
1.I sort the array of weights in decreasing order and "put" the largest weight in one group.
2.Then I keep adding weights to the other group until it becomes larger.
3.Then I start adding apples to the first group until this is one is larger and again start putting apples in the other group and keep on going like this until i reach the end of the array.
4.And then I print the difference between the total weights of the two groups.
My solution gives the correct answer with the sample test cases and a few others too but I am getting a WA, so can anyone suggest something I can do to correct my code.
Code:
~~~~~
#include <bits/stdc++.h>
using namespace std;
#define B begin()
#define E end()
#define I iterator
using pii = pair < int , int >;
using vi = vector < int >;
using llu = unsigned long long int;
using ll = long long int;
//ofstream cout ("op.txt");
...

Help required with CSES problem "Apple Division", to the first group until this is one is larger and again start putting apples
in the other group, 3.Then I start adding apples to the first group until this is one is larger and
again start putting

28.

Codeforces Round #269 (Div. 2) Hello Codeforces community! I'm happy to invite you to participate in Codeforces Round #269 for Division 2 which will be held [this Friday, September 26th](http://www.timeanddate.com/worldclock/fixedtime.html?day=26&month=9&year=2014&hour=19&min=30&sec=0&p1=166). As usual first division coders are invited to participate unofficially, I would appreciate a lot if they will join.
All problems are mine, so if you won't like them... well, you know whom to blame for those. I did my best in order not to disappoint you.
Since this is my first round, let me introduce myself. I'm 27, have around 7 years of programming experience and was never into ACM/ICPC and stuff like that before, learned words like "dynamic programming" couple of years ago from the algorithms course on Coursera and a bit later found this site. I'm from Saint Petersburg, Russia, was born and lived here until I became 24. Then I got married and me and my wife decided to go live somewhere else and we moved to Kyiv, Uk...

/fixedtime.html?day=26&month=9&year=2014&hour=19&min=30&sec=0&p1=166). As usual
first division coders

Announcement of Codeforces Round #269 (Div. 2)

29.

Codeforces Round #497 by Skyglow <img style="float: right; margin: 0px 30px 20px 50px;" src="/predownloaded/7a/cb/7acb70215acb214185582e201c004419b1a7622f.jpg">
Hello, everyone!
We are a Death Metal band [Skyglow](http://skyglowband.com/). Recently we released our first album. And since we happen to be sport programmers, we decided to make a Codeforces round in honor of this!
The round will take place on [contest_time:1007]. There will be five problems for each division, three of them will coincide. The problems were made up by me and [user:SirRembocodina,2018-07-09], the contest was also prepared with the help of [user:TeaPot,2018-07-09], [user:GrumpyKitten,2018-07-09], [user:mingaleg,2018-07-09] and [user:niyaznigmatul,2018-07-09]. Thanks to [user:demon1999,2018-07-10] and [user:winger,2018-07-13] for testing, our coordinator [user:arsijo,2018-07-09] and, of course, [user:MikeMirzayanov,2018-07-09] for Codeforces and Polygon platforms.
You can listen to the album by following the link:
- https://skygl...

://skyglowband.com/). Recently we released our first album. And since we happen
to be sport programmers, we

Announcement of Codeforces Round #497 (Div. 1)

Announcement of Codeforces Round #497 (Div. 2)

30.

Codeforces Round #563 (Div. 2) Hi!
I'm back with not one, not two, but three contests, although I have no promises about when to expect them....
The first of them, codeforces round #563, will take place on [contest_time:1174]. It's rated for the second division, but, as usual, first division participants can take part out of competition.
I'm the problemsetter of the round. I'd like to thank [user:KAN,2019-06-01] for coordinating the round (and his patience .. try coordinating ~20 problems), [user:arsijo,2019-06-02] for helping with the preparation, [user:Um_nik,2019-06-01], [user:opukittpceno_hhr,2019-06-02], [user:Aleks5d,2019-06-02], [user:Rifai,2019-06-03], [user:pllk,2019-06-03], [user:ulna,2019-06-03], [user:Ivan19981305,2019-06-03], and [user:PrianishnikovaRina,2019-06-03] for testing the round, and [user:MikeMirzayanov,2019-06-01] for the great codeforces and polygon platforms.
In this round, you'll be given 6 problems and 2 hours to solve them.
**UPD:** I decided to drop the 3 seconds rule. Th...

for the second division, but, as usual, first division participants can take
part out of competition., ]. It's rated for the second division, but, as usual, first division
participants can take part out

Announcement of Codeforces Round #563 (Div. 2)

31.

Codeforces Round #168 Hi everybody! :)
Codeforces Round #168 will start in hours. ~HamedSaleh,2013-02-20 and I (~havaliza,2013-02-20) are the authors of today's match. I'd like to thank ~Gerald,2013-02-20 and ~Delinur,2013-02-20 for helping us to prepare this contest and ~MikeMirzayanov,2013-02-20 for this great platform.
Hope you enjoy solving the problems as much as we enjoyed preparing them. ^.^
Good luck and have fun. :)
**UPD1.**
Score distribution will be:
**Div2 =** standard
**Div1 =** 500-1000-1500-2000-2000
**UPD2.**
Congratulations to the winners of both divisions. It's nice that after the contest all five winners of first division are red coders and all winners of the second division are first division coders!
**Div1:**
1. ~rng_58,2013-02-23
2. ~Petr,2013-02-23
3. ~Komaki,2013-02-23
4. ~msg555,2013-02-23
5. ~maksay,2013-02-23
**Div2:**
1. ~qph-Jeremy,2013-02-23
2. ~dojiboy9,2013-02-23
3. ~FreezingCool,2013-02-23
4. ~Hellis,2013-02-23
5. ~y346491470,...

of first division are red coders and all winners of the second division are
first division coders!, that after the contest all five winners of first division are red coders and
all winners of the second

Announcement of Codeforces Round #168 (Div. 1)

Announcement of Codeforces Round #168 (Div. 2)

32.

Codeforces Round #418 (Div. 2) _**418 I'm a teapot**_
Hi everyone! >///<
I'd like to invite you to Codeforces Round #418 which begins at [15:05 MSK on 7 June](https://www.timeanddate.com/worldclock/fixedtime.html?day=07&month=6&year=2017&hour=15&min=5&sec=0&p1=166). Please note that the timing is unusual.
This is my first round here! [user:KAN,2017-06-06] reviewed the contest and helped me through the preparation process, while [user:Alladdin,2017-06-06], [user:neckbosov,2017-06-06] and [user:Tommyr7,2017-06-06] tested all the problems, and [user:MikeMirzayanov,2017-06-06] and the awesome Codeforces and Polygon platforms made all this happen miraculously. This wouldn't have been possible without your efforts!
The round is **rated** for the second division, and participants from the first division can take part out of competition. As usual, there are five problems and two hours to solve them. The problems will feature... Well, let's wait and see :)
The scoring distribution will be announced later.
H...

! The round is **rated** for the second division, and participants from the
first division can take, The round is **rated** for the second division, and participants from the first
division can take

Announcement of Codeforces Round #418 (Div. 2)

33.

Codeforces Round #614 *"Can you hear me?"*
*"Vanessa...?"*
![ ](https://i.imgur.com/82l1lt0.png)
Hello Codeforces!
We are here to invite you to Codeforces Round #614 (Div. 1) and Codeforces Round #614 (Div. 2), which will take place at [contest_time:1292]. The round is rated for both divisions.
This is our first round including Div.1 parts, hopefully you'll find the problems interesting. ;)
This round is themed based on the Rayark Inc.'s rhythm game, [_"Cytus II"_](https://www.rayark.com/g/cytus2/). You are about to help our characters in various problems, whether inside or outside of the virtual Internet! Also, feel free to listen to the music tracks I've chosen from the game for each problem (and later, editorial!). ;)
Each division will be given **6** problems to solve in **2 hours.** The round's problems were prepared by Xuan-Quang ~xuanquang1999,2020-01-12 D. Nguyen, Duy-Bach ~Akikaze,2020-01-12 Le and Tuan-Dung ~low_,2020-01-12 To.
Interactive problem(s) might be found in this ...

. This is our first round including Div.1 parts, hopefully you'll find the
problems interesting

Announcement of Codeforces Round #614 (Div. 1)

Announcement of Codeforces Round #614 (Div. 2)

34.

A problem collection of ODE and differential technique ##A problem collection of ODE and differential technique
*This problem might be well-known in some countries, but how do other countries learn about such problems if nobody poses them.*
For those who are interested in well-known problems in China.
Thank [user:Elegia,2020-04-23] and [user:djq_cpp,2020-04-23] for developing this technique. Thank [user:tEMMIE.w.,2020-04-23] for reviewing this article.
####[Chain Reaction](http://uoj.ac/problem/50) in UOJ Round 3 By [user:vfleaking,2020-04-23]
**Statement**
You are given a set $A$, you need to compute $g_{i} = \frac{1}{2} \sum_{j,k}{i-1 \choose j}{i-1-j \choose k} g_jg_k$ where $i-1-j-k \in A$.
**Solution**
Let the EGF of $g$ be $x(t)$ and EGF of $A$ be $a(t)$. Thus $x'(t)=\frac{1}{2} a(t) x^2(t)+1$. We can solve this equation by D&C and FFT in $O(n\log^2 n)$. But there is a <s>slower</s> solution in $O(n\log n)$.
For a polynomial equation $f(x(t))=0$, we can use the Newton's method to solve it. If we find ...

, multiplication and division takes $O(n \log n)$ time, the we have the time
complexity $T(n)=T(n/2) + O(n\log n

35.

Registration for the first boot camp ‘Discover Izhevsk Winter 2020’ have opened Registration for the first boot camp ‘Discover Izhevsk Winter 2020’ have opened! It is time to prepare for the ICPC World Finals.
Training camps will be held from the February 9-21 at the Kalashnikov Izhevsk State Technical University. Training camps are split into Divisions which consist of: Division 1 — The “mirror” of Petrozavodsk training camp 2020. Phillip Rukhovich will be on tasks parsing. Division 2 — This division will be an analog of Division B/C of Moscow Workshops. Lectures and task parsing will be held by Vicktor Kamashev, gold medalist of ICPC WF 2008 and by other finalists of ICPC.
You could find timestable on our Workshop website: https://discover.it-edu.com/izhevsk/
There is also detailed information about fees, location and coaches. Make sure you register your team so we can book a place for you! Places are limited!
By the way, if you are still in school but would like to participate in the boot camps, we have prepared special conditions for you.
Offici...

Registration for the first boot camp ‘Discover Izhevsk Winter 2020’ have opened, University. Training camps are split into Divisions which consist of: Division
1 — The “mirror, Registration for the first boot camp ‘Discover Izhevsk Winter 2020’ have
opened! It is time

36.

Codeforces Round #394 (Div. 2) Hi there!
Codeforces round #394 for the second division will take place at the time of [Tuesday, 31 January 17:35 MSK](https://www.timeanddate.com/worldclock/fixedtime.html?day=31&month=1&year=2017&hour=17&min=35&sec=0&p1=166). Participants from the first division can compete out of competition. Contestants will have 2 hours and **6 problems** to solve.
<html>
<body>
<p>
<img src="http://codeforces.com/predownloaded/c0/ed/c0ed632751995e022101f7986487f528b63e876a.png" align=right hspace=20>
</p>
</body>
</html>
- Problems were developed by me (Vladislav Vishnevki) and Denis Anischenko ([user:altruist,2016-12-08]).
- Alexey Vistyazh ([user:netman,2016-12-08]) helped us as a contest coordinator.
- Aliaksandr Drapko ([user:sdryapko,2017-01-30]) and Alena Yaros were reading the statements carefully.
- Vlad Khala ([user:hapooo,2016-12-21]) tested the round.
- Olya Yakovchik drew amazing illustrations for the problems.
- Yuri Shilyaev ([user:hloya_ygrt,...

=2017&hour=17&min=35&sec=0&p1=166). Participants from the first division can
compete out of competition, =35&sec=0&p1=166). Participants from the first division can compete out of
competition. Contestants, Top 10 participants from first division: 1. [user:eddy1021,2017-01-31] 2.
[user:Myungwoo,2017

Announcement of Codeforces Round #394 (Div. 2)

37.

Codeforces Round #479 (Div. 3) Hello!
[contest:977] will start on [May 6 (Sunday) at 14:05 (UTC)] (http://www.timeanddate.com/worldclock/fixedtime.html?day=6&month=5&year=2018&hour=17&min=5&sec=0&p1=166). It will be the first Div.3 round in the history of Codeforces. You will be offered 6 problems with expected difficulties to compose an interesting competition for participants with ratings up to 1600. Probably, participants from the first division will not be at all interested by this problems. And for 1600-1899 the problems will be too easy. However, all of you who wish to take part and have rating 1600 or higher, can register for the round unofficially.
The round will be hosted by rules of educational rounds (extended ACM-ICPC). Thus, during the round, solutions will be judged on preliminary tests, and after the round it will be a 12-hour phase of open hacks. I tried to make strong tests — just like you will be upset if many solutions fail after the contest is over.
[Remember] (/blog/entry/59228) t...

the first division will not be at all interested by this problems. And for
1600-1899 the problems, , participants from the first division will not be at all interested by this
problems. And for 1600-1899

38.

Codeforces Round #408 (Div. 2) Hi, everyone!
**Unfortunately, the round was moved two hours later. Sorry for the inconvenience.**
It is my honor to announce that the Codeforces Round #408 **rated** for the second division is going to take place [tomorrow at 16:35 UTC](https://www.timeanddate.com/worldclock/fixedtime.html?msg=Codeforces+Round+%23408+%28Div.+2%29&iso=20170410T1635&p1=%3A&ah=2). As usual, participants from the first division will be able to participate out of competition.
As the author of this contest, I ([user:zoomswk,2017-04-09]) would like to thank [user:poomrokc,2017-04-09], [user:nisaruj,2017-04-09], and [user:Phoom,2017-04-09] for testing the problems, [user:KAN,2017-04-09] and [user:netman,2017-04-09] for their help in contest preparation, and [user:MikeMirzayanov,2017-04-09] for the awesome Codeforces and Polygon platforms. Cute graphics in this round are designed by my friend Chonphuech Sripongtanakul, so thanks to her also!
<img src="http://codeforces.com/predownloaded/75/8a/758a2...

the first division will be able to participate out of competition.

Announcement of Codeforces Round #408 (Div. 2)

39.

Codeforces Round #601 Hello Codeforces!
I am glad to invite you to [Codeforces Round #601](https://codeforces.com/contests/1254,1255), which will take place on [contest_time:1254]. The round will be rated for both divisions.
All problems in this round were created and prepared by a team of all-Vietnamese setters: [user:MofK,2019-11-18], [user:Prof.PVH,2019-11-18], [user:UncleGrandpa925,2019-11-18], [user:ngk,2019-11-18]. This is the first Vietnamese Div1 round. We tried to make both the problems and the statements interesting and hope that you will enjoy them!
There is an interactive problem in the round. You can read the guide for interactive problem [here](https://codeforces.com/blog/entry/45307).
We would like to give a lot of thanks to:
- [user:MikeMirzayanov,2019-11-18] for the amazing platforms Codeforces and Polygon.
- [user:arsijo,2019-11-18] for excellent coordination and many valuable advice for the round.
- Our team of testers: [user:MikeMirzayanov,2019-11-18], [user:KAN,20...

,2019-11-18]. This is the first Vietnamese Div1 round. We tried to make both
the problems

Announcement of Codeforces Round #601 (Div. 1)

Announcement of Codeforces Round #601 (Div. 2)

40.

Manthan — Codefest'19 Hello Codeforces!
I would like to invite you to [Manthan, Codefest'19](https://codeforces.com/contests/1208), which will take place on [Sunday, August 25, 2019 at 8:05 PM IST](https://www.timeanddate.com/worldclock/fixedtime.html?msg=Manthan%2C+Codefest%2719&iso=20190825T1435&ah=2). This is a **combined Div. 1 + Div. 2** round and is **rated** for participants from both divisions.
The Department of Computer Science and Engineering, IIT (BHU) is conducting Codefest from 23rd August — 25th August. Manthan, the algorithmic programming contest under the banner of [Codefest](https://codefest.tech/), is being held as a special Codeforces round. The round follows regular Codeforces rules.
![ ](/predownloaded/c8/01/c8015f2de382f967d9e531067ca03b5b743e5ed4.jpeg)
All problems in this round were created and prepared by [user:drastogi21,2019-08-23], [user:_shanky,2019-08-23], [user:enigma27,2019-08-23], [user:navpun31,2019-08-23], [user:KAN,2019-08-23] and me ([user:hitman623,201...

) — **INR 1,000** - **Codeforces T-shirts** to the participants who will be the
first to solve

Announcement of Manthan, Codefest 19 (open for everyone, rated, Div. 1 + Div. 2)

41.

Codeforces Round #294 (Div. 2) Hello, Codeforces!
My name is Adilet Zhaxybay, and together with Bekzhan Kassenov ([user:Bekzhan.Kassenov,2015-02-27]) we are authors of Codeforces #294, which will be held on [28th of February at 16:00 MSK](http://www.timeanddate.com/worldclock/fixedtime.html?day=28&month=2&year=2015&hour=16&min=0&sec=0&p1=166). This is our first Codeforces round and we are happy to invite all of you to participate in it. The round will be rated for the second division, however, participants from the first division can, as usually, participate in it unofficially.
As far as we know, it is the first Codeforces round, which was completely prepared by the authors from Kazakhstan. We are very honored by this fact and hope that everything will go great. We are encouraging other participants from our country to join us — I am sure, that you can prepare a lot of very nice problems. Preparing Codeforces round is possible ;)
We want to thank all the people, who helped us to prepare the contest: Max Akh...

in it. The round will be rated for the second division, however, participants
from thefirst division can, to participate in it. The round will be rated for the second division,
however, participants from thefirst

42.

Educational Codeforces Round 11 Hello, Codeforces!
Educational Codeforces Round 11 will take place on [8 april 2016 at 18:00 MSK](http://www.timeanddate.com/worldclock/fixedtime.html?msg=Educational+Codeforces+Round+11&iso=20160408T1500) for the first and the second divisions.
\<The changes in the last paragraph\>
The round will be unrated for all users and it will be held with extented ACM ICPC rules. You will have two hours to solve six problems. After that you will have one day to hack any solution you want. You will have access to copy any solution and test it locally.
If you have ideas for some problems or maybe already prepared problems that you can't use in rounds or official competitions, you can write to me.
It seems that it is harder to invent interesting simple problems (like A and B) than difficult ones. So don't be afraid to suggest interesting simple or very simple tasks (of course the difficult tasks are also needed). Please send only the problems for which you know the solution with c...

) for the first and the second divisions.

Announcement of Educational Codeforces Round 11

43.

Results and Editorial for mBIT 2021 June Round **UPD: Editorials have been released!**
Thank you to everyone who participated in the mBIT Spring 2021 competition today! All of the information on this blog post is also available in our [archive](https://mbit.mbhs.edu/archive/2021s/), which includes the full leaderboard.
Problems and Editorials
==================
Test your solutions on our Codeforces Gyms: [Standard](https://codeforces.com/gym/103110), [Advanced](https://codeforces.com/gym/103109)
- [Standard problems](https://mbit.mbhs.edu/archive/2021s/standard.pdf) / [Standard solutions](https://mbit.mbhs.edu/archive/2021s/standard_editorial.pdf)
- [Advanced problems](https://mbit.mbhs.edu/archive/2021s/advanced.pdf) / [Advanced solutions](https://mbit.mbhs.edu/archive/2021s/advanced_editorial.pdf)
Results
==================
First, we would like to congratulate the team **Texas** _(Adam Bertelli, Dilhan Salgado, Zack Lee)_ for being the first team to find all of the Among Us references hidden in the problems! Wi...

================== First, we would like to congratulate the team **Texas**
_(Adam Bertelli, Dilhan Salgado, Results ================== First, we would like to congratulate the team
**Texas** _(Adam

44.

Codeforces Round #704 (Div. 2) Hi everybody,
This Tuesday there will be a <a href="http://mos-inf.olimpiada.ru">Moscow programming competition for school students of grades from 6 to 9</a>. This contest is prepared by Moscow Olympiad Scientific Committee that you may know by Moscow Open Olympiad, Moscow Team Olympiad and Metropolises Olympiad (rounds <a href="https://codeforces.com/blog/entry/21185">327</a>, <a href="https://codeforces.com/blog/entry/23309">342</a>, <a href="https://codeforces.com/blog/entry/43615">345</a>, <a href="https://codeforces.com/blog/entry/47769">376</a>, <a href="https://codeforces.com/blog/entry/50613">401</a>, <a href="https://codeforces.com/blog/entry/54350">433</a>, <a href="https://codeforces.com/blog/entry/55201">441</a>, <a href="https://codeforces.com/blog/entry/57981">466</a>, <a href="https://codeforces.com/blog/entry/58229">469</a>, <a href="https://codeforces.com/blog/entry/61638">507</a>, <a href="https://codeforces.com/blog/entry/62440">516</a>, <a href="https://codeforce...

(rating below 2100). As usual, participants from the first division can
participate in a contest out, below 2100). As usual, participants from the first division can participate in
a contest out

Announcement of Codeforces Round #704 (Div. 2)

45.

The second division is growing and gaining strength <div><div>After analyzing the Division 2 rounds results and the difficulty of the problems, we decided to expand it Division 2 and to include the "blue" participants. Thus, the second division will consist of members with a rating from 0 to 1649. </div><div><br></div><div>This is primarily due to the fact that I think the problems from the second division rounds are interesting and useful to the "blue" participants. At these competitions, we often give training problems on common themes of sports programming. In addition, it is seen that in order to be blue enough to solve 1-2 problems on the first division competitions. This leads to the fact that such members do not increase their skills. </div><div><br></div><div>Note that we are considering the possibility to divide "yellow" the participants into two colors, since this group is very huge and contains members of widely differing skills and abilities. </div><div><br></div><div><b>UPD. The yellow group was separat...

The second division is growing and gaining strength, problems on the first division competitions. This leads to the fact that such
members do not increase, to be blue enough to solve 1-2 problems on the first division competitions.
This leads to the fact

46.

Invitation to CodeChef July CookOff 2021 (with prizes!) We invite you to participate in CodeChef’s [July Cookoff](https://www.codechef.com/COOK131?utm_source=codeforces_blog&utm_medium=organic&utm_campaign=JulyCook), today — 28th July, from [8:00 PM — 10:30 PM IST](https://www.timeanddate.com/worldclock/fixedtime.html?msg=July+Cook-off+2021&iso=20210728T2000&p1=44&ah=2&am=30). **Note the unusual time**.
There will be **7 problems** in all divisions.
The contest will be rated for all three Divisions. The July Cook-Off also marks the launch of our new prize structure for global & Indian participants. More details are given below.
Joining us on the problem setting panel are:
- Contest Admins: Ashish [user:ashishgup,2020-12-19] Gupta and Jatin [user:jtnydv25,2021-05-30] Yadav
- Head Admin: Alex [user:Um_nik,2021-06-26] Danilyuk
- Tester: Aryan [user:aryanc403,2021-07-28] Choudhary
- Statement Verifier: Riley [user:1-gon,2021-07-28] Borgard
- Editorialist: Vichitr [user:Vichitr,2021-07-28] Gandas, Srikkanth [u...

global Division One users will get **$100** each. - Non-Indians will receive
the prize via money, - Top ten Indian Division One coders will get Amazon Vouchers worth **Rs.
3750** each. - The rest

47.

Moscow Pre-Finals ACM ICPC Workshop in April, 2017 Hello, Codeforces!
------------
![ ](http://codeforces.com/predownloaded/ab/3e/ab3e0a8c6f5552b5ba6ee44621653b71519be012.jpg)
==================
In the lead-up to the ACM-ICPC World Finals we invite everyone to participate in **Moscow Pre-Finals ACM ICPC Workshop**, that will be held **10-17 of April 2017** at the campus of the Moscow Institute of Physics and Technology ( MIPT). The event is organized by one of the leading Russian universities, MIPT and ITMO.
The Moscow Pre-Finals ACM ICPC Workshop is the unique event in the world of competitive programming. Every year teams from 20 different countries from Europe, Asia and the USA meet at one platform. Many teams participated in this Workshop turn out to be the prize-winners and winners of the the ACM-ICPC World Finals. In 2016 8 out of 13 teams that were awarded medals at the Finals took part in the Moscow Pre-Finals Workshop ACM ICPC at MIPT.
This year the organisators have made possible **the remote participation** whic...

in the first division (Div.A) and other teams who want to train before the
next season in the second, to participate in the first division (Div.A) and other teams who want to train
before the next season

48.

Educational Codeforces Round 12 Hello, Codeforces!
Note! The day of the contest here was wrong. Now it's fixed.
Educational Codeforces Round 12 will take place on [20 april 2016 at 18:00 MSK](http://www.timeanddate.com/worldclock/fixedtime.html?msg=Educational+Codeforces+Round+12&iso=20160420T1500) for the first and the second divisions.
<Advertising space is still available>
The round will be unrated for all users and it will be held with extented ACM ICPC rules. You will have two hours to solve six problems. After that you will have one day to hack any solution you want. You will have access to copy any solution and test it locally.
If you have ideas for some problems or maybe already prepared problems that you can't use in rounds or official competitions, you can write to me.
It seems that it is harder to invent interesting simple problems (like A and B) than difficult ones. So don't be afraid to suggest interesting simple or very simple tasks (of course the difficult tasks are also needed). Plea...

) for the first and the second divisions.

Announcement of Educational Codeforces Round 12

49.

All division 1,2,3, ed, global round links and helper for virtual participations Hello people. Hope you all are safe and in a good health.
Here is a small effort to get you the links of all the Div1, Div2, Div3, Educational and Global rounds.
Along with the links, an option to get the unique contests is there. **If selected, only those contests will be displayed, of which you have never attempted any question.** Thus, one can give virtual contest of that round.
For all contests : https://clashofcodes.herokuapp.com/getContests
For website : https://clashofcodes.herokuapp.com/landing
<img src="/predownloaded/24/2c/242c252ce89550e0e69b843b7eb1aba8f0667429.png">
_Along with this, we have some other features when you login._
_After you login, you first had to set the handle, then only you can access the statistics._
Thanks [user:umanggupta001122,2021-04-30] for working along.
Note : We are working on the website and are looking to add more features.
Feedbacks are highly appreciated.

All division 1,2,3, ed, global round links and helper for virtual participations, _After you login, you first had to set the handle, then only you can access the
statistics._, first had to set the handle, then only you can access the statistics._ Thanks

50.

Help needed in CSES problem: Food Division Hi everyone,
I am stuck at this problem '[Food Division](https://cses.fi/problemset/task/1189)' from 'CSES Problem Set' for about 2 weeks. I have tried below things but still, I can't come up with the correct solution:
1. I used the approach in solving the '[BALIFE — Load Balancing](https://www.spoj.com/problems/BALIFE/)' problem from SPOJ. Basically, I iterated over the circle, used the current node as the starting point, and then applied the algorithm used in the BALIFE problem.
2. Also, I wrote minimum cost maximum flow tester to stress test the above approach on random tests. The above approach is giving correct answers on random tests with input size upto 1000. So, I am unable to debug my above approach with smaller test cases.
3. I have also tried basic greedy strategies like saturating the highest/lowest sources/sinks first.
As a result, I am requesting your help. Any hint/similar problems with editorials would be very helpful.

Help needed in CSES problem: Food Division, 3. I have also tried basic greedy strategies like saturating the highest/lowest
sources/sinksfirst., Hi everyone, I am stuck at this problem '[Food Division
](https://cses.fi/problemset/task/1189

51.

Frequently Asked Questions <div> This is the list of frequently asked questions concerning Codeforces work and answers to them.</div>
<ol>
<li><a href="#q1">What is Codeforces? What kind of a site/resource is it?</a></li>
<li><a href="#q2">What should I do to participate in contests? Is preliminary registration required?</a></li>
<li><a href="#q3">What are the rules of the contests?</a></li>
<li><a href="#q4">What languages can I use to solve problems here? Are there any problem solving examples?</a></li>
<li><a href="#q5">I would like to organize a Codeforces round with my problems. What should I do to achieve that?
Are the authors entitled to get any reward?</a></li>
<li><a href="#q6">What other rules are on Codeforces?</a></li>
<li><a href="#q7">Which technical details are useful to know about the Codeforces' testing system?</a></li>
<li><a href="#q8">What are the rating and the divisions?</a></li>
<li><a href="#q9">What is contribution?</a></li>
<li...

that you're part of the first division. Usually two types of contests are held
on Codeforces: for the second, the contest for the second division and you are in the first one), then you
can register for the contest, . if it's the contest for the second division and you are in the first one),
then you can

52.

Questions about First Contest So I just did a Division 2 contest (todays), and I managed to only do one question and was #13000+. Since it was my first ever contest, I checked if my rating changed and it didn't. Does this mean I did so bad that they couldn't give me a rating or do I have to wait a few hours? Also does anyone know if I should continue doing Div. 2 contests since those are the only ones I see registerable atm, or should I just wait for Div. 3 contests since I can barely answer one question on Division 2? Any answers or help will be appreciated thanks!

Questions about First Contest, So I just did a Division 2 contest (todays), and I managed to only do one
question and was #13000

53.

Codeforces Round #404. Announcement. Hello, Codeforces!
Tomorrow, in [March 15, 2017 at 18:05 MSK](https://www.timeanddate.com/worldclock/fixedtime.html?msg=Codeforces+Round+%23404+%28Div.+2%29&iso=20170315T1805&p1=166&ah=2) a regular **rated** Codeforces round for participants from the second division will take place. As usual, participants from the first division can take part out of competition. It's my second contest and I hope you'll like it more than my [previous one](http://codeforces.com/contest/734/).
As usual, there will be five problems on the contest and two hours to solve them. I advice you to read all the problems' statements **attentively**. Also check all your solutions for correctness even if they passed all the pretests. Verdict <b><font color="#008000">Pretests passed</font></b> doesn't mean that the solution is completely correct! I wish you to enjoy the contest and learn something new solving the problems.
Like in the last time, the problems will be about Anton and his friends.
Great thank...

the first division can take part out of competition. It's my second contest
and I hope you'll like it more, , participants from the first division can take part out of competition. It's
my second contest and I

Announcement of Codeforces Round #404 (Div. 2)

54.

Codeforces Round #373 Hi everyone!
Codeforces Round #373 (Div. 1 + Div. 2) will take place on [23 September 2016 at 16:05 MSK](http://www.timeanddate.com/worldclock/fixedtime.html?day=23&month=9&year=2016&hour=16&min=5&sec=0&p1=166). Please note that **the timing is unusual**.
This time tasks for you were prepared by me (Matvey Aslandukov) and my brother [user:_XuMuk_,2016-09-21] (Andrew Aslandukov). It is our first codeforces round and we hope you'll enjoy it. We want to say special thanks to [user:Seyaua,2016-09-21] (Ievgen Soboliev), [user:alexfetisov,2016-09-21] (Alexandr Fetisov) and [user:winger,2016-09-21] (Vladislav Isenbaev) for testing the problems, [user:GlebsHP,2016-09-21] for his help with the contest preparation, and [user:MikeMirzayanov,2016-09-21] for the excellent platforms Polygon and Codeforces.
Coincidentally, the date of the round falls on my birthday, so I am very happy that I can spend that day surrounded by our friendly community :)
There will be five problems and two hou...

first codeforces round and we hope you'll enjoy it. We want to say special
thanks to [user:Seyaua

Announcement of Codeforces Round #373 (Div. 1)

Announcement of Codeforces Round #373 (Div. 2)

55.

Invitation to TOKI Open Contest March 2017 Hello Codeforces Community, TOKI Open Contest is back! :D
We would like to invite you to participate in this TOKI Open Contest March 2017. TOKI Open Contest is our (Indonesian's) monthly/bi-monthly online contest. Starting last month, we had decided to make this contest international! You may see the information of last month contest [here](http://codeforces.com/blog/entry/50318). Every problem is written in both Bahasa Indonesia and English.
Starting this month, we divide the contest into **two divisions**: Division 1 and Division 2. It is pretty similar to the divisions in Codeforces. You are free to register in any division (it's extremely OK if you are a Div2 Codeforces user and register to our Division 1 contest)! The expected difficulties of the problems are much the same with the first four Codeforces' contest problems (A to D).
TOKI Open Contest March 2017 will be held on [Saturday, 25 March 2017, 19.00 — 21.00 Western Indonesian Time (UTC+7)](https://www.timeanddate.c...

into **two divisions**: Division 1 and Division 2. It is pretty similar to the
divisions in Codeforces, Starting this month, we divide the contest into **two divisions**: Division 1
andDivision 2

56.

Codeforces Round #498 (Div. 3) Hello!
Finally I am freed from the big part of summer cares and I can continue the preparation of Div. 3 rounds! I decided to add something written by me to this blog because [user:TryToKnowMe,2018-07-15] (and many others, i think) [noticed](https://codeforces.com/blog/entry/60377?#comment-442051) that i am really copy and paste this text from one announcement to another changing only contest name and start time. But... Who knows, may be this time which is saved by copy-pasting the announcement allows me to prepare the problems better?... Let it stay a mystery. So, let's go.
[contest:1006] will start at [contest_time:1006]. You will be offered 6 problems with expected difficulties to compose an interesting competition for participants with ratings up to 1600. Probably, participants from the first division will not be at all interested by this problems. And for 1600-1899 the problems will be too easy. However, all of you who wish to take part and have rating 1600 or higher, can re...

from the first division will not be at all interested by this problems. And
for 1600-1899, , participants from the first division will not be at all interested by this
problems. And for 1600

Announcement of Codeforces Round #498 (Div. 3)

57.

Codeforces Round #390 (Div. 2) THi Codeforces!
I'm glad to announce that [today at 17:35 MSK](https://www.timeanddate.com/worldclock/fixedtime.html?msg=Codeforces+Round+%23390&iso=20170106T1735&p1=166&ah=2) will take place first round in the new year — Codeforces Round #390 for the second division. Traditionally, first division participants will be able to take part out of competition.
Round was prepared by me, Alex [user:netman,2017-01-06] Vistyazh.
Many thanks to Nikolay [user:KAN,2017-01-06] Kalinin for his help in contest preparation and Mike [user:MikeMirzayanov,2017-01-06] Mirzayanov for the Codeforces and Polygon platforms.
You will be offered five problems and two hours to solve them.
Scoring will be announced closer to beginning of the round.
**UPD:** Scoring is **500 — 1000 — 1500 — 2000 — 2500**
**UPD2:**
There were some troubles during contest — in problem C first pretest wasn't equal to first sample, and unfortunately this problem was solved ...

year — Codeforces Round #390 for the second division. Traditionally, first
division, first round in the new year — Codeforces Round #390 for the second division.
Traditionally,first

Announcement of Codeforces Round #390 (Div. 2)

58.

Invitation to Alkhwarizm — 2018 ![ ](/predownloaded/e3/97/e397dc0023df73c082d86704b371b5c05474c164.jpg)
Hello, Codeforces!
I would like to invite you all to [Alkhwarizm 2018](https://www.codechef.com/ALKH2018), the flagship coding event of [Aparoksha](https://aparoksha.org/) — The Annual tech fest of IIIT-Allahabad.
It will contain 10 tasks of varying difficulty and you will get 5 hours of time to fight this fierce battle of _Codditch_(another version of [Quidditch](http://harrypotter.wikia.com/wiki/Quidditch)).
The contest will be an [External rated contest](https://blog.codechef.com/2017/03/09/a-star-studded-rating-system/). We are happy to announce that [Alkhwarizm 2017](https://www.codechef.com/ALKH2017) was the first External rated contest in the history of Codechef and this year [Alkhwarizm 2018](https://www.codechef.com/ALKH2018) is the first External rated contest for both Divisions after the [New Rating Division](https://www.codechef.com/ratings/divisions) system on Codechef.
The problem...

) was the first External rated contest in the history of Codechef and this year
[Alkhwarizm 2018

59.

Contest round #683 Division 2 Add candies tests. In the first problem of this round the number of operations is the number of bags and you have to include all the indices of the bags.
The order of the indices doesn't matter because every bag gets added with the number of candies of the unaffected bag, in the end filling every bag with equally n(n+1)/2 candies.
This is what I understand.
There is no need to minimize m operations either, so can anyone tell me why this submission is wrong?
https://codeforces.com/contest/1447/submission/98465795

Contest round #683 Division 2 Add candies tests., In the first problem of this round the number of operations is the number of
bags and you have

60.

Montgomery Blair Informatics Tournament 2021 Spring Round (Registration live!) **Competitors can join our Discord server [here](https://discord.gg/CuWRkC8pG5)**.
The [Montgomery Blair HS Computer Team](https://www.mbhscompteam.org/) is proud to present the fourth iteration of the semi-annual **Montgomery Blair Informatics Tournament (mBIT)**, which will be held online from [10:00 AM — 2:00 PM EDT](https://www.timeanddate.com/worldclock/fixedtime.html?msg=Montgomery+Blair+Informatics+Tournament+%28mBIT%29+2021+Spring+Round&iso=20210612T10&p1=263&ah=4) on **Saturday, June 12 (6/12/21)**. If you are interested in competing, please register at https://mbit.mbhs.edu/. The contest will be hosted on our personal servers at https://mbit.live/. All problems were written by the Montgomery Blair Computer Team, including [user:12tqian,2021-01-01], [user:gabrielwu,2021-04-01], [user:galen_colin,2021-05-14], [user:smax,2021-05-14], [user:meiron03,2021-05-14], [user:Blastman,2021-05-14], [user:alien_lover,2021-05-14], [user:czhang2718,2021-06-05], and [user:csytrn,2021...

]! mBIT is split into two divisions: **Standard** and **Advanced**. Teams may
choose whichdivision

61.

Codeforces Round #435 (Div. 2) Hello Codeforces!
I'm glad to announce that on [Sep/19/2017 15:05 UTC](https://www.timeanddate.com/worldclock/fixedtime.html?day=19&month=9&year=2017&hour=18&min=5&sec=0&p1=166) Codeforces Round #435 for the second division will take place. As usual, First division participants can take part out of competition.
This round was prepared by me.
I'd like to thank [user:mohammedehab2002,2017-09-17] for writing the statements and the editorials and testing the round, [user:Livace,2017-09-17],[user:Alladdin,2017-09-17],[user:gainullin.ildar,2017-09-17] and [user:cdkrot,2017-09-17] for testing the round, [user:gritukan,2017-09-17] for helping us in contest preparation, translating the statements into Russian and making one of the problems more interesting, [user:KAN,2017-09-17] and [user:Ahmad_Elsagheer,2017-09-17] for giving their opinions and thoughts about the problems and [user:MikeMirzayanov,2017-09-17] for the great Codeforces and Polygon platforms.
You will be given 6 proble...

#435 for the second division will take place. As usual, First division
participants can take part out, division will take place. As usual, First division participants can take part
out of competition.

Statements of Codeforces Round #435 (Div. 2)

62.

Yandex.Algorithm 2011 Qualification 2 (Tutorial) <p></p><h2>Task A. Double Cola</h2><div><div>Let's designate characters on the first letter of the name. The queue looks like: SH-L-P-R-G, through 5 cans: SH-SH-L-L-P-P-R-R-G-G, through 10 cans: SH-SH-SH-SH-L-L-L-L-P-P-P-P-R-R-R-R-G-G-G-G.</div><div><br></div><div>The regularity is clear, and the solution is very simple: we will be iterated on $p$ - we will find such minimum $p$ that $5 \cdot 2^p> n$ (thus if this number is less or equally we will subtract it from $n$) then we know that at first $2^p$ Sheldon's stand, then $2^p$ Leonard's and so on. And now we can easily answer who took a can number $n$ (namely there was a person with number $n / 2^p$ in sequence SH-L-P-R-G (in 0-indexation).</div></div><h2>Task B. Sets</h2><div><div>For the solution the following important fact is required to us: we will admit elements $v$ and $u$ are in one set then in any of $n \cdot (n - 1) / 2$ of sequences from the input data where meets $v$ $u$ necessarily meets. And...

Task A. Double Cola
Let's designate characters on the first letter,
Task C. General Mobilization
At first we will estimate from above the maximum

Announcement of Yandex.Algorithm 2011: Qualification 2

63.

Register for the Montgomery Blair Informatics Tournament (mBIT) 2020 Fall Round! If you are interested in participating in the **Montgomery Blair Informatics Tournament (mBIT)**, which will be held online from [12:00-4:00 PM EST](https://www.timeanddate.com/worldclock/fixedtime.html?msg=Montgomery+Blair+Informatics+Tournament+%28mBIT%29+Fall+2020+Round&iso=20201114T12&p1=263&ah=4) on **Saturday, November 14 (11/14/20)**, please register at https://mbit.mbhs.edu/. The contest will be hosted on our personal servers at https://mbit.live/. All problems were written by the [Montgomery Blair HS Computer Team](https://codeforces.com/ratings/organization/2457), including [user:12tqian,2020-10-28], [user:gabrielwu,2020-10-28], [user:galen_colin,2020-10-28], [user:smax,2020-10-28], [user:meiron03,2020-10-28], [user:Blastman,2020-10-28], [user:czhang2718,2020-10-28], and [user:csytrn,2020-10-28]. Special thanks to [user:balbit,2020-11-12] for spending hours test solving our hardest problems!
mBIT is split into two divisions: **Standard** and **Advanced**. Teams may choose ...

which division to compete in. Standard division problems are roughly USACO
Bronze to Silver

64.

Codeforces Beta Round #74 <p>Hello everyone!<br><br>I am an author of problems of today round. This round is for both divisions. There will be 7 problems, the first 5 of them are for the second division and the last 5 are for the first one.<br><br>About points of problems. Today they are nonstandard:<br>for div2: 500-1000-1500-2000-2000<br>for div1: 500-1000-1000-1500-2500<br>Be careful.<br><br><a class="rated-user user-admin" href="../../../profile/RAD" title="Штаб, RAD">RAD</a> helped me for preparing the round. <a class="rated-user user-black" href="../../../profile/Delinur" title="Не в рейтинге, Delinur">Delinur</a> translated statements into English.<br><br>Good luck ans have fun.</p><p>UPD.<br> winners of the first division<br>
1. <a href="../../../profile/peter50216" title="Капитан peter50216" class="rated-user user-violet">peter50216</a><br>2. <a href="../../../profile/tourist" title="Генерал tourist" class="rated-user user-red">tourist</a><br>
3. <a href="../../../profile/ACRush" title="Генерал ...

UPD.
winners of the first division
1.
, divisions. There will be 7 problems, the first 5 of them are for the second
division and the last 5, problems, the first 5 of them are for the second division and the last 5 are
for thefirst one.

Announcement of Codeforces Beta Round #74 (Div. 1 Only)

Announcement of Codeforces Beta Round #74 (Div. 2 Only)

65.

Codeforces Round #501 (Div. 3) <copy-pasted-part>
Hello!
[contest:1015] will start at [contest_time:1015]. You will be offered 6 or 7 problems with expected difficulties to compose an interesting competition for participants with ratings up to 1600. Probably, participants from the first division will not be at all interested by this problems. And for 1600-1899 the problems will be too easy. However, all of you who wish to take part and have rating 1600 or higher, can register for the round unofficially.
The round will be hosted by rules of educational rounds (extended ACM-ICPC). Thus, during the round, solutions will be judged on preliminary tests, and after the round it will be a 12-hour phase of open hacks. I tried to make strong tests — just like you will be upset if many solutions fail after the contest is over.
You will be given 6 or 7 problems and 2 hours to solve them.
Note that **the penalty** for the wrong submission in this round (and the following Div. 3 rounds) is **10 minutes*...

for participants with ratings up to 1600. Probably, participants from the first
division will not be at all, . Probably, participants from the first division will not be at all interested
by this problems

Announcement of Codeforces Round #501 (Div. 3)

66.

Invitation to CodeChef July Lunchtime 2021 - Saturday, 31st July, 6 PM IST We invite you to participate in CodeChef’s [July Lunchtime](https://www.codechef.com/LTIME98?utm_source=codeforces_blog&utm_medium=organic&utm_campaign=JulyLtime), this Saturday, 31st July.
Time: [6 PM — 9 PM IST](https://www.timeanddate.com/worldclock/fixedtime.html?msg=July+Lunchtime+2021&iso=20210731T1800&p1=44&ah=3).
The contest will be rated for all three Divisions. We also have a new prize structure for global & Indian participants. More details are given below.
Joining us on the problem setting panel are:
- Setters: Soumyadeep [user:soumyadeep_21,2021-07-31], Souradeep Paul, Piyush [user:present_sir,2021-07-31] Mittal, Vansh [user:kvansh,2021-07-31] Kaul, Ayush Singh, Tianyi, Rahim [user:Nots0fast,2021-07-31] Mammadli, Prasant [user:prasant21,2021-07-31] Kumar
- Head Admin: Alex [user:Um_nik,2021-07-31] Danilyuk
- Contest Admin: Radoslav [user:Radoslav11,2021-07-31] Dimitrov
- Tester: Riley [user:1-gon,2021-07-31] Borgard
- Statement Verifier: Jak...

**Prizes:** **Global Rank List:** Top 10 global Division One users will get
$100 each. Non, :** **Global Rank List:** Top 10 global Division One users will get $100 each.
Non-Indians

67.

Invitation to CodeChef December Cook-Off 2019 Merry Christmas y'all!
![ ](/predownloaded/c0/9a/c09a3a77d3160550fa9ce16f1f0f095454e51562.jpg)
I invite you to join us at CodeChef’s December Cook-Off. A 2.5 hours contest with five challenging problems which will be a great chance for you to test your skills.
If you have some original and engaging problem ideas, and you’re interested in them being used in the CodeChef's contests, you can share them [here](https://www.codechef.com/problemsetting/new-ideas).
I hope you will participate with your fellow programmers and enjoy the contest problems. Joining me on the problem setting panel are:
- Setter and Editorialist: [user:KMAASZRAA,2019-12-21] (Kasra Mazaheri)
- Tester: [user:ckodser,2019-12-21] (Arshia Soltani)
- Statement Verifier: [user:Xellos,2019-12-21] (Jakub Safin)
- Admin: [user:teja349,2019-12-21] (Teja Vardhan Reddy)
- Mandarin Translator: [user:UoA_ZQC,2019-12-21] (Qingchuan Zhang)
- Vietnamese Translator: Team VNOI
- Russian Translator: [user:Fedosik,20...

contestants solve the common problems of both divisions first? It seemed
unnatural to me that everyone

68.

USACO 2014-2015 First Contest This contest is different from old contests of [usaco](http://usaco.org).
For bronze division there is has 4 problem.
For silver division there is has 3 problem.
For gold division there is has 3 problem.
And each problem has different number of testcase.
Full feedback.
Maybe after contest some testcase will be add or change.
The following languages are available :
`en, fr, es, ru, vi (gold only),`
`hy (silver only),`
`ka (bronze and silver only)`
GL & HF .
You can see more information [here](http://usaco.org).

USACO 2014-2015 First Contest, For bronze division there is has 4 problem., For gold division there is has 3 problem., For silver division there is has 3 problem., This contest is different from old contests of [usaco](http://usaco.org). For
bronzedivision

69.

Codeforces Round #396 (Div. 2) Hello Codeforces!
I'm glad to announce that on [Feb/07/2017 17:05 UTC](http://timeanddate.com/worldclock/fixedtime.html?day=7&month=2&year=2017&hour=20&min=5&sec=0&p1=166) Codeforces Round #396 for the second division will take place. As usual, First division participants can take part out of competition.
This round was prepared by me and [user:mohammedehab2002,2017-02-06].
I'd like to thank [user:moaz123,2017-02-06] for helping us prepare the round, [user:zoooma13,2017-02-06] for testing some problems, [user:KAN,2017-02-06] for helping us in contest preparation and for translating the statements into Russian and [user:MikeMirzayanov,2017-02-06] for the great Codeforces and Polygon platforms.
You will be given 5 problems and 2 hours to solve them.
The scoring distribution will be announced later.
**UPD 500-1000-1500-2000-2500**
**UPD** [editorial](http://codeforces.com/blog/entry/50294) is ready
**UPD** Congratulations to the winners!
Div1+Div2:
1. [user:V...

for the second division will take place. As usual, First division participants
can take part out, will take place. As usual, First division participants can take part out of
competition.

Announcement of Codeforces Round #396 (Div. 2)

70.

Codeforces Round #439 (Div. 2) Hi, Codeforces!
I'm quite excited to invite you to Codeforces Round #439 (Div. 2) which takes place at [16:35 MSK on 6 October](https://www.timeanddate.com/worldclock/fixedtime.html?day=06&month=10&year=2017&hour=16&min=35&sec=0&p1=166) and lasts for two hours.
One of the five problems is created by [user:quailty,2017-10-05], and the others are created by me. This is our first round here.
The round couldn't have been realized without efforts of [user:KAN,2017-10-05] and [user:gritukan,2017-10-05]. Besides, I also want to say thanks to our testers: [user:cyand1317,2017-10-05], [user:visitWorld,2017-10-05], [user:Nisiyama_Suzune,2017-10-05], [user:cdkrot,2017-10-05] and [user:gainullin.ildar,2017-10-05]. Thanks for your help to the contest. Also, thanks to [user:MikeMirzayanov,2017-10-05] with the fantastic Codeforces and Polygon platforms.
The contest will consist of five problems and it is **rated** for Div. 2 contestants. The same as before, Div. 1 contestants can take pa...

is created by [user:quailty,2017-10-05], and the others are created by me.
This is ourfirst round here

71.

Codeforces Rating System <div class="from-renderer"><p> As some users have already noticed - contest rating has been added
to Codeforces. For now it is in beta too, but it looks very adequate.
Here's how it is calculated. </p>
<p> Each person is characterized by their rating, the number <i>R</i>. If person <i>A</i>'s rating is <i>R</i><sub><i>A</i></sub>, and person <i>B</i>'s is equal to <i>R</i><sub><i>B</i></sub>, then the
formula </p>
<div style="text-align: center;">
<img src="http://upload.wikimedia.org/math/b/2/b/b2b35a42d6c3a2e0d4f07106d0cb4ef0.png">
<br></div>
gives the probability that <i>A</i> will get a higher position than <i>B</i> in the
round final standings. By the way, here everything is very close to the
<a href="http://en.wikipedia.org/wiki/Elo_rating">Elo rating</a>. <p> Before updating your rating after the end of the round,
for each participant his seed is calculated, that is the place that
the participant is expected to take in this competiti...

* if it is the first contest for a participant, his seed is calculated as 1 +
n, technical points:
* if it is the first contest for a participant, his seed

72.

ABBYY Cup 2.0 is waiting for you! <img src="http://www.abbyy.ru/adx/aspx/adxgetmedia.aspx?DocID=a21b125e-53fb-401f-9c30-6a4a8a7ab859" style="float:left;margin:0 1em;"/></a>
The [ABBYY](http://www.abbyy.com/?NoRedirect=1) company, a leading provider of document recognition, document capture, is holding a student online [ABBYY Cup](http://www.abbyy.ru/science/students/cup/) contest together with the **Codeforces** and **Saratov State University**. We’ve been taken into account the feedback from the previous contest into consideration. So, this year’s contest will consist of two divisions.
If you belong to the second division on Codeforces, that is, if you’ve never participated in programming contest or have little experience of participating, then your best choice is to apply for participating in the second (easier) ABBYY Cup division. This division will have problems that are even easier than those given on [ABBYY Cup 1.0](http://www.abbyy.ru/science/students/cup/problems/). The first (and more difficult) division ...

Cup 1.0](http://www.abbyy.ru/science/students/cup/problems/). The first (and
more difficult)division, in the Codeforces’ second division. The Codeforces’ first division users can
take part in the seconddivision out, /). The first (and more difficult) division will be mainly interesting to the
first division Codeforces, The first division contest starts on [April 28, Saturday, at 4.00
PM](http://timeanddate.com

73.

Using recurrent neural networks to predict next tokens in the java solutions Hi everyone,
Today we are going to show few demos of Sequence to Sequence models for code completion.
But before diving into details, we, as usual, want to ask you to participate in collecting data for the future models in our labeling platform here:
https://r-nn.com
There are real money rewards associated with all the tasks in the platform.
The Demo
========
In the first demo we trained a seq2seq model, more on which below, on all the Accepted java solutions on CodeForces. The goal of the model is to predict the next token based on all the tokens seen so far. We then plug the output of the model into a code editor (the arena on the video is an unfinished project I will write about separately) to see how it behaves when one actually solves a competitive programming problem. Here we are solving problem A from Codeforces Round 407:
https://youtu.be/icoAK6yMCjg
Notice how early on the model nearly perfectly predicts all the tokens, which is not surprising, since ...

The second interesting moment is what happens when we are printing the answer.
Atfirst when

74.

Invitation to the Bay Area Programming Contest on March 27th Hello Codeforces!
We are excited to invite you to the first ever Bay Area Programming Contest! The contest is open for everyone to participate, and will start on [Saturday, March 27, 2021 at 9:00<sup>UTC-7</sup>](https://www.timeanddate.com/worldclock/fixedtime.html?msg=Bay+Area+Programming+Contest&iso=20210327T09&p1=1240&ah=4).
The contest was written by me, [user:pocafup,2021-03-25], [user:EndlessVoid,2021-03-25], [user:ant101,2021-03-25], and [user:NikhilC,2021-03-25].
There will be two divisions, the Novice division and the Advanced division. The Novice division is for participants with one year or less of programming experience and little to no contest experience, and the Advanced division is for everyone who doesn't meet that criteria. Each division will have 8 problems to solve in 4 hours. We will be giving out prizes totaling to at least 400 dollars for the top pre-college students in both divisions. This is an **individual contest**.
The contest will conducted in C...

Hello Codeforces! We are excited to invite you to the first ever Bay Area
Programming Contest

75.

ZeptoLab Code Rush 2014 <img src="http://assets.codeforces.com/images/zepto2014/image06.png" style="width:190px;float:right;margin:0 1em 1em 1em;"/>
A coder can apply his breathtaking coding skills not only in different search engines but also in the mobile game industry. It is an option in Russia. If you do not believe — check this out: ZeptoLab company that created the world famous Cut the Rope game offers you the opportunity to see this for yourself. And yes, we are in Moscow.
It's not a secret that those who strive to achieve top coding skills — work hard, including work on his self-education. Here in ZeptoLab we aim to create the area that strongly encourages self-development. Specifically, we have recently purchased a company library with everything necessary to get new knowledge, an improvised reading room with sofas and armchairs.
<center>
<img src="http://assets.codeforces.com/images/zepto2014/image08.jpg" style="width:400px;"/>
</center>
We also conduct developer's contest ...

the first time that Mike teaches in such format, there are hardly any more
examples of such corporate

Announcement of Zepto Code Rush 2014

76.

Codeforces Round #416 (Div. 2) (based on MSPU Olympiad 2017) Hello everyone!
<html>
<body>
<p>
<img src="/predownloaded/f4/15/f41572c1d2f36ef70a1d6b4d4c477de4a745f32c.png" align=right hspace=20>
</p>
</body>
</html>
[27 May, 12:35 MSK](http://timeanddate.com/worldclock/fixedtime.html?day=27&month=5&year=2017&hour=12&min=35&sec=0&p1=166) new codeforces round takes place for participants from the second division. Participants from the first division can participate out of competition. Round consists from 5 problems, and you will be given 2 hours to solve them. **Pay attention on round start time**.
The problems will be almost the same as on Open Olympiad of Mozyr State Pedagogical University, which takes part parallel to the round. The full problem set would be in codeforces gym soon. I am also going to tell you about the Olympiad a bit later.
- The problemsetters are: me (Vladislav Vishnevski), Valery Kameko ([user:Valerich,2017-05-26]) and Yury Shilyaev ([user:hloya_ygrt,2017-05-26]).
- The testers are: Alex Kern...

. Participants from the first division can participate out of competition.
Round consists from 5

Announcement of Codeforces Round #416 (Div. 2)

77.

Moscow Pre-Finals ACM ICPC Workshop 2018 <img src="/predownloaded/a0/46/a046fd0faa1f59749fd4245d555f19b5bef3e527.png"></img>
Hello everyone!
We’re glad to tell you that [Moscow Pre-Finals ACM ICPC Workshop](https://it-edu.mipt.ru/en/spring-training-2018) will be held at Moscow Institute of Physics and Technology from **21 of March to 1 of April, 2018**.
The Moscow Pre-Finals ACM ICPC Workshop is the unique event in the world of competitive programming. Many teams participated in this Workshop turn out to be the prize-winners and winners of the the ACM-ICPC World Finals. In 2017 8 out of 12 teams that were awarded medals at the Finals took part in the Moscow Pre-Finals Workshop ACM ICPC at MIPT.
The Workshop is going to be held in accordance with the **two divisions** scheme. We invite finalists to participate in the **first division** and other teams who want to train before the next season in the **second division**.
The Workshop is organized by MIPT, University ITMO and SPbU.
The official language is **E...

finalists to participate in the **first division** and other teams who want to
train before the next season

78.

Invitation to CodeChef August Long Challenge 2018 sponsored by ShareChat! Hello CodeForces Community!
We are thrilled to invite you to participate in the August Long Challenge 2018 sponsored by ShareChat. In addition, there are some exciting internship and full-time job opportunities by ShareChat for Indian programmers in the August Long Challenge 2018. For more details, you may visit the contest page.
I hope you will join your fellow programmers and enjoy the contest problems. Joining me on the problem setting panel are:
- Problem Tester: [user:AllCatsAreBeautiful,2018-08-02] (Mark Mikhno)
- Problem Authors: [user:likecs,2018-08-02] (Bhuvnesh Jain), [user:asheshvidyut,2018-08-02] (Ashesh Vidyut), [user:step_by_step,2018-08-02] (Stepan Filippov), [user:pieguy,2018-08-02] (David Stolp), [user:allllekssssa,2018-08-02] (Aleksa Plavsic), [user:bciobanu,2018-08-02] (Bogdan Ciobanu), [user:mraron,2018-08-02] (Aron Noszaly), [user:Sheoran_Jitu,2018-08-02] (Jitender Sheoran), [user:PraveenDhinwa,2018-08-02] (Praveen Dhinwa)
- Problem Editorialist: [use...

to winners@codechef.com). First to solve each problem individually: 100 laddus
(For problems common

79.

My double divsion operator blog helped in a Codeforces Contest Hello Codeforces community,
A few months ago, I had noticed a fact and had written a blog on how the Double division operator should be used for floor division instead of math.floor() in Python. This is because the single division operator behaves abnormally for very large numbers in Python, and thus math.floor() on them would work incorrectly.
[Link to my blog.](https://www.geeksforgeeks.org/benefits-of-double-division-operator-over-single-division-operator-in-python)
Today in [Codeforces Educational Round #86 Question C](https://codeforces.com/contest/1342/problem/C), I first submitted a solution in which I used the Single Division Operator in floor division and got WA. But then I realised the large constraints which could cause an error here, so on changing the single division operator to Double Division Operator, I got AC.
[My WA Solution](https://codeforces.com/contest/1342/submission/78231960)
[My AC Solution](https://codeforces.com/contest/1342/submission/78233071...

/78233071) This is the first time my
[blog](https://www.geeksforgeeks.org/benefits-of-double-division, /C), I first submitted a solution in which I used the Single Division Operator
in floordivision, This is the first time my
[blog](https://www.geeksforgeeks.org/benefits-of-double-division-operator

80.

A Beautiful Technique for Some XOR Related Problems ## Inspiration
I'm very excited about this blog, as it took me quite a lot of effort and scavenging through the internet to completely grasp the concept of this technique(That's probably because I have almost zero knowledge in Linear Algebra or I'm just plain dumb). So I feel like I genuinely conquered a challenge, and I really want to share it with someone. But there's no way my CP friends circle will believe it, they'll think I'm just trying to show off :P
So here I am, sharing it on CF. I also created a [personal blog](https://drschwad.github.io/), so that if I ever feel like sharing something again(not only about CP), I can write a blog there. I also added this same post [there](https://drschwad.github.io/2019-08-06-z2-space-xor-trick/), you can read it there if you prefer dark theme. I'll be pleased to hear any thoughts on the blog or if I can improve it in some way ^\_^
## Introduction
Since it concerns Linear Algebra, there needs to be a lot of formal stuff going on ...

of first type instructing you to insert numbers in the array(_without
removal_, I don't know how to solve

81.

Codeforces Round #376 (Div. 2) Hi everybody!
Tomorrow at [09:35 UTC](http://www.timeanddate.com/worldclock/fixedtime.html?day=16&month=10&year=2016&hour=12&min=35&sec=0&p1=166) there will be Codeforces Round #376 that is dedicated for the second division. At the same time there will be a Moscow School Team Olympiad, and, as a nice tradition, we bring you a CodeForces round based on its problems. Unfortunately, this time we weren't able to come up with a good problemset for a first division contestants, but, as usual, we invite first division to participate unofficially in this round.
Problems were prepared by [user:timgaripov,2016-10-15], [user:platypus179,2016-10-15], [user:wilwell,2016-10-15], [user:Flyrise,2016-10-15], [user:ipavlov,2016-10-15] and [user:gritukan,2016-10-15] under my control. We would like to thank members of jury of the Team Olympiad: [user:Endagorion,2016-10-15], Helen Andreeva and [user:GlebsHP,2016-10-15], who also works as a coordinator from the CodeForces side. Also we are very gratef...

to come up with a good problemset for a first division contestants, but, as
usual, we invitefirst

Announcement of Codeforces Round #376 (Div. 2)

82.

Want to know about division 3 Yesterday, I had participated in div 3 contest and solved one problem but I hadn't get any points nor it is showing in my contest section that I participated ? I wantto know why as first time I participated in div 3 contest

Want to know about division 3, nor it is showing in my contest section that I participated ? I wantto know
why asfirst time I

83.

Weekly Training Farm #26 Editorial 我們發現中文有一些顯示問題，之後會再處理。
The Chinese version has some display issue with latex for now.
A. Numbers
If $D > 0$, then there are at most $D - 1$ integers between the $X$-th largest integer and the $X$-smallest integer. So the answer would be $2X + D - 1$.
If $D = 0$, then the $X$-th largest integer is the exactly same integer as the $X$-smallest integer. So the answer is $2X - 1$.
If $D < 0$, then the case with the largest number of integers would be: the $X$-smallest integer is the very next integer larger than the $X$-largest integer if sorted ascendingly. So the answer would be $2X - 2$.
Overall, the answer can be expressed as $2X + \max(D - 1, -2)$. Time complexity is $O(1)$.
如果 $D > 0$，則第 $X$ 大的數跟第 $X$ 小的數之間最多有 $D - 1$ 個數字。所以答案為 $2X + D — 1$。
如果 $D = 0$，則第 $X$ 大的數跟第 $X$ 小的數其實是同一個數字。所以答案為 $2X — 1$。
如果 $D < 0$，則最多數字的情況為：如果由小到大排序後，第 $X$ 小的數恰好排在第 $X$ 大的數之後。所以答案為 $2X — 2$。
整體而言，答案可以寫成 $2X + \max(D — 1, -2)$。時間複雜度為 $O(1)$。
B. Power
There are a...

When maintaining $C(a+k,b+k)$. There are two operations: multiple and division.
To multiple by $v, \ mod\ 3$ with multiple and division operations. Initially $n = 2$ and the
operations are 1.) multiply

84.

Barcelona ACM-ICPC Programming Bootcamp 2017 <div style="float:right;margin:0 1em 1em 1em;text-align:center;">
<a href="http://harbour.space/"><img src="http://d9hhrg4mnvzow.cloudfront.net/in.harbour.space/icpc/2b828bc0-logo-circled-126_02s02s02s02s000000.png"/></a>
<br/><br/><br/>
<a href="http://it-edu.mipt.ru/en/fall_training_2016"><img src="http://d9hhrg4mnvzow.cloudfront.net/in.harbour.space/icpc/569fc7e8-workshop-logo-nodate_04702z04602z000000.png"/></a>
</div>
Hello all.
This coming February of 2017 will be a new experience for me: I'll be one of the coaches who will teach at the
<a href="http://in.harbour.space/icpc/">Barcelona ACM-ICPC Bootcamp</a> hosted by Harbour.Space University. In addition, here are some well-known coaches from our community: [user:Endagorion,2016-12-08], [user:GlebsHP,2016-12-08], [user:Michael,2016-12-08], [user:Jacob,2016-12-08] and [user:snarknews,2016-12-08]. The camp will be hosted in collaboration with Moscow Workshops ACM ICPC by MIPT. The same proven effective studying techniq...

techniques will be used at the Barcelona Bootcamp. For me, it will be the first
teaching experience

85.

Codeforces Round #469 (based on Moscow Open Olympiad) Hi everybody,
Today there will be the first day of Moscow Open Olympid, that is the personal programming competition that is held in Moscow each spring. This contest is prepared by Moscow Olympiad Scientific Committee that you may know by Moscow Team Olympiad, Moscow Olympiad for Young Students and Megapolises Olympiad (rounds [327](http://codeforces.com/blog/entry/21185), [342](http://codeforces.com/blog/entry/23309), [345](http://codeforces.com/blog/entry/43615), [376](http://codeforces.com/blog/entry/47769), [401](http://codeforces.com/blog/entry/50613), [433](http://codeforces.com/blog/entry/54350), [441](http://codeforces.com/blog/entry/55201), [466](http://codeforces.com/blog/entry/57981)).
Open Olympiad consists of the most interesting and hard problems that are proposed my a wide community of authors, and that is why we decided to give you an opportunity to crack the complete problemset of the contest by making some kind of an experiment. Tomorrow we are going to conduct ...

Hi everybody, Today there will be the first day of Moscow Open Olympid, that is
the personal

Announcement of Codeforces Round #469 (Div. 1)

Announcement of Codeforces Round #469 (Div. 2)

86.

Prepare for USACO Hi Codeforces,
The first round of USACO is probably going to start within a month. I am currently a sophomore in high school and I wish to enter Platinum division this time. I'm pretty confident that I can enter Gold division, but I am still uncertain in how to train more effectively so that I can achieve my goal.
So here is the thing, a lot of experienced people suggest that the best way to practice is to do a lot of random problems on CF with suitable ratings. I have been training that way for a while, and I can now solve most of the problems from 1700 — 1800.
However, is doing random problems really helpful for USACO performances? Because OI is still quite different from CF problems, and most of the USACO Gold problems are among DP, Graph Theory (short paths, MST etc.) and sometimes Data Structure and Strings (at least that's what I think). So I also made several problem lists on those topics which consists of many past gold problems. But I found my training process...

The first round of USACO is probably going to start within a month. I am
currently a sophomore

87.

Educational Codeforces Round 42 (Rated for Div. 2) Hello Codeforces!
On [April 10, 14:35 UTC](https://www.timeanddate.com/worldclock/fixedtime.html?day=10&month=4&year=2018&hour=17&min=35&sec=0&p1=166) Educational Codeforces Round 42 will start.
Series of Educational Rounds continue being held as [Harbour.Space University](https://harbour.space/) initiative! You can read the details about the cooperation between [Harbour.Space University](https://harbour.space/) and Codeforces in the <a href="http://codeforces.com/blog/entry/51208">blog post</a>.
This round will be **rated for Div. 2**. It will be held on extented ACM ICPC rules. After the end of the contest you will have one day to hack any solution you want. You will have access to copy any solution and test it locally.
You will be given **7 problems** and **2 hours** to solve them.
The problems were prepared by me and Alex [user:fcspartakm,2018-04-09] Frolov.
We'd like to thank Nikolay [user:KAN,2018-04-09] Kalinin, Grigory [user:gritukan,2018-04-09] Reznikov,...

A and B — and especially recognise division A’s winner: Team SDV — Vasily, in both divisions A and B — and especially recognise division A’s winner: Team
SDV &mdash

Announcement of Educational Codeforces Round 42 (Rated for Div. 2)

88.

MindCoding 2nd Round 2017 Hi, dear friends,
It's a pleasure to announce you that the second MindCoding round for both Div.1 and Div.2 of 2017's Edition will take place on Thursday, March 23. We are currently making every effort for this edition to be a successfull one and you are welcome to join our community.
MindCoding is a high-performing international coding competition, structured in 4 online rounds & 1 final stage, that'll take place in Cluj-Napoca, Romania, between 28th-30th of April 2017.
The second round will last 90 minutes and the contest has the same structure as the first round (and the following two qualification rounds), consisting of 4 problems of scores ranging between 100 and 1000 which will decrease in time. We remind you that the total score to be counted towards qualification in the final round will be computed as the sum of each participant's score in all the 1st division rounds they competed in.
**If you haven't participated during the first round, you are welcome to take part ...

The second round will last 90 minutes and the contest has the same structure as
thefirst round

89.

[Tutorial] Generating Functions in Competitive Programming (Part 2) Welcome to Part 2 of my tutorial on generating functions. The [first part](https://codeforces.com/blog/entry/77468) focused on introducing generating functions to those without any background in generating functions. In this post, I will demonstrate a few applications of generating functions in CP problems. Let us start with some relatively straightforward examples.
Note: Unless stated otherwise, all computations are done modulo a convenient prime (usually $998244353$). Also, $[n]$ denotes the set $\\{1,2,...,n\\}$.
### Blatant Applications in Counting Problems
**Problem.** [AGC 005 Problem F](https://atcoder.jp/contests/agc005/tasks/agc005_f) You have a tree $T$ with $n$ vertices. For a subset $S$ of vertices, let $f(S)$ denote the minimum number of vertices in a subtree of $T$ which contains all vertices in $S$. For all $1 \le k \le n$, find the sum of $f(S)$ over all subsets $S$ with $|S| = k$.
Constraints: $n \le 2 \cdot 10^{5}$.
<spoiler summary="Solution">
First, ...

Welcome to Part 2 of my tutorial on generating functions. The [first
part](https://codeforces.com

90.

[Gym] 2018 ACM Amman Collegiate Programming Contest — editorial The tutorials for problems B & E were written by [user:1am,2018-06-03], D by [user:The-Legend,2018-06-03], F by [user:Qumair,2018-06-03], J & K by [user:Motarack,2018-06-03] and M by [user:abo_od303,2018-06-03]. Thank you guys for also reviewing the rest of the tutorial!
#### [A. Careful Thief](http://codeforces.com/gym/101810/problem/A)
It’s enough to try all segments of size $K$ that either starts with the start of a range or ends with the end of a range, suppose that the optimal solution is somewhere that starts in some range and ends in some other range (possibly ranges of zeroes), then shifting the segment to one direction will increase the answer, and shifting it in the other direction will decrease it until you reach the boundary of the range, or if both ranges have the same amount of money then shifting will not affect the answer.
This can be done using a sorted array of the ranges and for each range that starts with $l_i$ we can binary search for $l_i + k - 1$ and to get...

The first iteration, Abood will start to give his friends cookies starting from
the $1^{st}$ friend

91.

Solutions to Google Code Jam 2017 Round1A-- Problem A, B A. Alphabet Cake
I solved this problem by first filling the array row by row, and then column by column.
For each row, at first I enumerate from the first element to the last one until I find an element that is not '?', and then break the loop. If such an element that is not '?' does not exist, it means that this row consists of only '?'. Such a row is skipped, however do not worry since it will be implemented later. Now suppose that we have found such an element which is not '?' and denote it as a variable x (char x;). Then, I enumerate from the first element again, and
1) when a '?' is met, just replace it with x;
2) when x is met (note that x must be the first letter that is met, since I immediately break the loop when the first element that is not '?' is found), do nothing (or replace it with x, which achieves the same result);
3) when a letter different from x is met, just update x with this letter, and go to step 1).
After the above operations, for instance, ...

At first, we should consider under what conditions that two packages
corresponding to different

92.

Canada Cup <div style="float:right;margin:0 1em 1em 1em;"><a href="https://diagram.ca/"><img src="http://codeforces.com/predownloaded/60/1a/601ad2651390b1ff2232c003a354c60ac059d570.png"/></a></div>
Hi Codeforces,
I'm excited to announce the Canada Cup, the first Codeforces contest to be sponsored by <a href="https://diagram.ca/">Diagram</a>!
This is a rated Codeforces round (with T-shirts!) for both divisions which will take place on <a href="http://www.timeanddate.com/worldclock/fixedtime.html?day=22&month=10&year=2016&hour=18&min=0&sec=0&p1=166">October 22 at 11:00am EDT</a>.
<b>Although the contest is organized in Canada, all competitors worldwide will be able to compete and win prizes.</b>
The problems for this round were written me ([user:zxqfl,2016-10-15]) and the Codeforces team. I'd like to thank:
- My coauthors for contributing great problems to the round
- [user:GlebsHP,2016-10-15] for his help in preparation
- [user:MikeMirzayanov,2016-10-15] for creating Codeforce...

Codeforces, I'm excited to announce the Canada Cup, the first Codeforces
contest to be sponsored

Announcement of Canada Cup 2016

93.

Topcoder SRM 500 Сегодня в 19:00 по Москве состоится юбилейный TopCoder SRM 500.<br><br>Подробная информация:<br><br>Please note due to Daylight Savings, TopCoder time has changed to Eastern Daylight Time or UTC -4.<br>
<br>
TopCoder(R) Single Round Match <span class="il">500</span> is scheduled
for Saturday, March 19, 2011 at 12:00 UTC -4 hours. In recognition of
this milestone, TopCoder will be awarding 5,000 in cash prizes plus
more! So get ready for the most prestigious TopCoder <span class="il">SRM</span> in years and give yourself a chance at becoming part of history!<br>
<br>
<span class="il">SRM</span> <span class="il">500</span> will begin at
12:00 UTC-4 with registration opening 3 hours prior to match time.
Registration will be limited to 2,100 slots on a first come first serve
basis so be sure to register early!<br>
<br>
Please be sure to check here for the start time in your time zone:<br>
<a href="http://www.timeanddate.com/worldclock/fixedtime.html?&day=19&...

, respectively.
* The first and second place competitors in each division two room will
receive 60

94.

Announcement: 2nd Hello Barcelona programming bootcamp in collaboration with Moscow Workshops ACM ICPC Hello, Codeforces!
I am pleased to announce [the 2nd Hello Barcelona Programming Bootcamp in collaboration with Moscow Workshops ACM ICPC](http://in.harbour.space/icpc/acm-icpc-hello-barcelona-bootcamp-autumn-2017/), which will be hosted by our partner [Harbour.Space University](https://harbour.space/) together with [Moscow Workshops ACM ICPC](https://it-edu.mipt.ru/en/), [ITMO University](http://en.ifmo.ru/en/), [Moscow Physics and Technology University](https://mipt.ru/en/), [Saint Petersburg State University](http://english.spbu.ru/) and Codeforces!
<br/>
<center>
<a href="http://in.harbour.space/icpc/acm-icpc-hello-barcelona-bootcamp-autumn-2017/"><img src="http://d9hhrg4mnvzow.cloudfront.net/in.harbour.space/icpc/acm-icpc-hello-barcelona-bootcamp-autumn-2017/5a56f9db-logo-acm-icpc-12_0d70280d701x000005.png"/></a>
</center>
<br/>
The boot camp will be held from September 27th to October 5th in Barcelona. This time it will be at the beautiful and technologically mind-be...

the first Hello Barcelona programming Bootcamp in February, I left the event
feeling inspired from

95.

SPC — Final Contest : ) Hola, budding coders of the SPC and Codeforces!
On [contest_time:338837], [Programming Club IIT Madras](http://cfi.iitm.ac.in/club/Programming%20Club) will host The [Speed Programming Contest (SPC) — Final Contest](https://codeforces.com/group/xK9ngmaNEM/contest/338837) and we would like to invite all of you for the same.
This is the Last round of the 2021 series of Summer Programming Camp Contests. It will be a combined **unrated** round for all divisions : )
The contest consists of 12 problems [ICPC Style Scoring] to be solved in 150 minutes. While all the problems will be exciting and fun for the participants of the Camp, we believe that the first 4 problems would be easy for the experienced coders & the later problems would be challenging even for a Master.
The round will provide a good range of problems in terms of difficulty, and every problem would definitely be thrilling for the Participants.
The prizes for the **Official Participants** — All the Stud...

will be exciting and fun for the participants of the Camp, we believe that the
first 4 problems would be easy

96.

USACO First Contest 2015-2016 Hello everybody!
This morning I realized that I was about to miss the contest since I completely forgot about it so just a quick reminder. It can be done from 11th to 14th this month :)
PS: According to usaco.org, this year there is going to be a new Platinum division :)

USACO First Contest 2015-2016, : According to usaco.org, this year there is going to be a new Platinum division
:), PS: According to usaco.org, this year there is going to be a new Platinum
division :)

97.

Moscow International Workshop ACM ICPC 2015 **From 10 to 21 November 2015** the Moscow International Workshop ACM ICPC is going to be held at Moscow Institute of Physics and Technology.
Moscow International Workshop ACM ICPC presents programming education and training camp for students. It is traditionally held by the [Moscow Institute of Physics and Technology](http://mipt.ru/) and the [Lomonosov Moscow State University](http://msu.ru) and this year is going to be the fifth time the event is taking place.
The workshop is aimed at training and educating students in programming for successful participation in the ACM ICPC.
The official language is English.
The workshop schedule is planned to have 9 full workdays that include daily contests and problem analyses, as well as lectures and time for upsolving. In the evenings, there will be sports and other activities. Besides, a plenary session with the participation of the world's scientists on advanced algorithms and technologies in the IT-industry is scheduled on the first...

on the first day (10th of November). Contests are moderated by Oleg
Khristenko: coordinator

98.

[Suggestion] When should a round be rated for a registered user? Dear codeforces community. Lately, I have started participating in some division 1 rounds, and I experience a weird issue. Suppose some Div1's problems are >= 2100 in difficulty. Then most purples after reading the problems choose to quit and not do the round. The purples that do choose to do the round, might not even solve the first problem, but the main issue is that a round is only rated for you if you submit. The latest codeforces div1 round (round #707) had about 1300 registered participants, but only ~700 submitted something, and only ~620 solved a problem. So solving problem A with bad timing causes you to be last place, despite doing better than half of the participants.
I suggest that a round should be rated for a user if he views one of the problems of the round as a registered participants. Was this suggested before? I think atcoder had some contests that worked that way but I am not sure.. Any way, the current system causes low div1's to simply quit, causing the people t...

Dear codeforces community. Lately, I have started participating in some division
1 rounds, and I

99.

Solutions to Codeforces Beta Round #22 A, B, C, D, E A. Second Order Statistics
This problem asks to find out the smallest element which is strictly larger than the minimum one. One simple way to solve this is to sort the array a[n] which stores the input data in an increasing order, and then find the first element that is different from a[0]. If such an element exists, then output this as the answer; otherwise output "NO" since all elements are exactly the same.
B. Bargaining Table
This is equivalent to finding out a rectangular which contains no '1's and has the largest perimeter at the same time. A trivial method is to check each feasible rectangular, i.e., enumerate the upper left point which takes O(mn) complexity and for each fixed upper left point, enumerate the bottom right point which takes O(mn) complexity as well, and finally check that whether this rectangular consists of only '0's or not, which takes O(mn) complexity. If it contains no '1's, then calculate the current perimeter and update the value of largest perime...

First note that if m=n-1 must

100.

The Lyft Level 5 Challenge <a href="https://www.lyft.com/level5/" style="width:150px;float:right;margin:0 1em 1em 1em;"><img src="https://assets.codeforces.com/images/lyft-logo.png"/></a>
We are thrilled to announce the Lyft Level 5 Challenge hosted by Codeforces and sponsored by Lyft. This international competition consists of two, timed rounds, where competitors will solve multiple algorithmic puzzles much like the ones we’re solving at Level 5, Lyft’s self-driving division.
**Round 1**: Elimination
On <a href="https://www.timeanddate.com/worldclock/fixedtime.html?day=7&month=10&year=2018&hour=20&min=0&sec=0&p1=166">Sunday, October 7, 2018 at 10:00 PDT</a>, the competition kicks off with a standard two-hour round of seven problems. The top 100 participants will win a Lyft Level 5 Challenge t-shirt. The top 30 contestants located in the San Francisco Bay area will be invited to Round 2.
**Round 2:** Final at Level 5
On <a href="https://www.timeanddate.com/worldclock/fixedtime.html?day=4&month=11&...

the ones we’re solving at Level 5, Lyft’s self-driving division. **Round 1**:
Elimination On

101.

[Tutorial] Math note — Möbius inversion If you've ever taken some lessons on competitive programming, chances are that you have already heard about one of the most famous formula: the Möbius inversion. This article is aimed to provide some basic insight on what is the Möbius inversion, as well as how to apply it in various programming tasks.
Prequisite
==================
If you are not familiar with the linear sieve and multiplicative functions, it is recommended that you read about them first [here](http://codeforces.com/blog/entry/54090).
I will introduce some frequently used notations and lemmas first.
Notation
------------------
1. $[P]$ refers to the boolean expression, i.e. $[P]=1$ when $P$ is true, and $0$ otherwise.
2. $\lfloor x \rfloor$ refers to rounding $x$ down to the nearest integer. Thus $\lfloor \frac{q}{p} \rfloor$ refers to the integer division.
3. $d|n$ means that d can divide n (without a remainder).
The following functions are all multiplicative functions, where $p$ is a prime numbe...

and multiplicative functions, it is recommended that you read about them first
[here](http://codeforces.com/blog

102.

[Tutorial] Rolling hash and 8 interesting problems [Editorial] **UPD**: while I was translating this post from Russian to English, [user:dacin21,2018-07-06] wrote his post, more advanced, [link](http://codeforces.com/blog/entry/60442). I hope that my post will help beginners, but in my post more rough estimates.
And in Russia we call **rolling hashes** as a **polynomial hashes**.
Hello, codeforces! This blogpost is written for all those who want to understand and use polynomial hashes and learn how to apply them in solving various problems. I will briefly write the theoretical material, consider the features of the implementation and consider some problems, among them:
1. Searching all occurrences of one string of length $n$ in another string length $m$ in $O(n + m)$ time
2. Searching for the largest common substring of two strings of lengths $ n $ and $ m $ $(n \ge m) $ in $O((n+m \cdot log(n)) \cdot log(m))$ and $O(n \cdot log(m))$ time
3. Finding the lexicographically minimal cyclic shift of a string of length $ n $ in $ O(n \cdo...

many operations getting remainder from the integer division, sometimes on the
border with TLE

103.

SPC Round #003 Hola, budding coders of the SPC and Codeforces!
On [contest_time:337838], [Programming Club IIT Madras](http://cfi.iitm.ac.in/club/Programming%20Club) will host The [Speed Programming Contest (SPC) Round #003](https://codeforces.com/group/xK9ngmaNEM/contest/337838) and we would like to invite all of you for the same.
To register for the contest: [Click Here](https://codeforces.com/contestInvitation/205bc917cbe2a2aadff6424228fcc04b027cb683)
This is the third round of the 2021 series of Summer Programming Camp. It will be a combined **unrated** round for all divisions : )
The contest consists of 10 problems [ICPC Style Scoring] to be solved in 120 minutes. While all the problems should be exciting and fun for the participants of the Camp, we believe that the first 6 problems should be easy for the experienced coders, the next 3 should be somewhat challenging, while the last problem might need some time even for a Master to solve.
The prizes for the **Official Participants*...

should be exciting and fun for the participants of the Camp, we believe that
thefirst 6 problems

104.

Codeforces Round #300 Editorial (+challenges) As usual, a challenge comes with every problem. I tried not to repeat the mistakes of my previous editorials and made sure that all challenges have a solution =) (except for the _italics_ parts that are open questions, at least for me). Go ahead and discuss them in the comments! General questions about problems and clarification requests are welcomed too.
**UPD**: I added codes of my solutions for all the problems. I didn't try to make them readable, but I believe most part of them should be clear. Feel free to ask questions.
[problem:538A]
Let me first clarify the statement (I really wish I didn't have to do that but it seems many participants had trouble with the correct understanding). You had to erase exactly one substring from the given string so that the rest part would form the word `CODEFORCES`. The (somewhat vague) wording `some substring` in the English translation may be the case many people thought that many substrings can be erased; still, it is beyond my understa...

be clear. Feel free to ask questions. [problem:538A] Let me first clarify the
statement (I

Tutorial of Codeforces Round #300

105.

Codeforces Round #570 (Div. 3) <almost-copy-pasted-part>
Hello!
[contest:1183] will start at [contest_time:1183]. You will be offered 6 or 7 problems (or 8) with expected difficulties to compose an interesting competition for participants with ratings up to 1600. However, all of you who wish to take part and have rating 1600 or higher, can register for the round unofficially.
The round will be hosted by rules of educational rounds (extended ACM-ICPC). Thus, during the round, solutions will be judged on preliminary tests, and after the round it will be a 12-hour phase of open hacks. I tried to make strong tests — just like you will be upset if many solutions fail after the contest is over.
You will be given 6 or 7 (or 8) problems and 2 hours to solve them.
Note that **the penalty** for the wrong submission in this round (and the following Div. 3 rounds) is **10 minutes**.
[Remember] (/blog/entry/59228) that only the <i>trusted participants of the third division</i> will be included in the ...

/entry/59228) that only the trusted participants of the third division will be
included

Announcement of Codeforces Round #570 (Div. 3)

106.

Fast Walsh Hadamard Transforms and it's inner workings One of my favorite algorithms out there is FWHT, but sadly there are not many tutorials about it. So here's a simple attempt by me (feedback is appreciate).
**Note:** I will be explaining FWHT via DFT/FFT and as such good understanding of theory behind DFT/FFT is **required**. Also, I won't be going into Hadamard matrices, since I don't know much about them myself.
What is FWHT? Suppose you have two sets $ (1, 2, 2) $ and $(3, 4, 5)$ and want to perform all possible xor operations between these two sets, the resulting set being $(1, 1, 2, 4, 5, 6, 6, 7, 7)$. This is commonly called xor convolution. Naively you'd do this in $O(n^2)$ time, where $n=2^k$, $k$ = maximum number of bits (you maintain a frequency count for each possible value and loop on all possible pair). FWHT let's you do this in $O(n\log n)$ time via some <strike>black magic</strike> FFT tricks. We first build the frequency arrays upto $n=2^k$, apply FWHT to turn them into some mysterious point-value form, perform ...

do this in $O(n\log n)$ time via some black magic FFT tricks. We first build

Codeforces (c) Copyright 2010-2021 Mike Mirzayanov

The only programming contests Web 2.0 platform

Server time: Aug/03/2021 20:37:03 (i2).

Desktop version, switch to mobile version.

Supported by

User lists

Name |
---|