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

Results

1.

open-source

Last visit:  4 years ago
Registered:  4 years ago
2.
By tourist, history, 7 years ago, translation, In English
Codeforces Global Round 5 <img src="/predownloaded/2e/e2/2ee2f0f95f05aae6ca6f47812dae2dc2aabf277b.png" style="width:200px; float:right; margin: 0 1em 1em 1em"/> Hey! On [contest_time:1237] we will host [contest:1237]. It is the fifth round of a new series of [Codeforces Global Rounds](https://codeforces.me/blog/entry/65002) supported by XTX Markets. The rounds are open for everybody, the rating will be updated for everybody. The round will last for 2 hours 30 minutes, 8 problems are waiting for you, and one of them will be proposed in two versions. Scoring distribution: **500 &mdash; 750 &mdash; (750 + 750) &mdash; 2000 &mdash; 2500 &mdash; 3000 &mdash; 3750 &mdash; 4000** The prizes for this round: - 30 best participants get a t-shirt. - 20 t-shirts are randomly distributed among those with ranks between 31 and 500, inclusive. The prizes for the 6-round series in 2019: - In each round top-100 participants get points according to the [table](https://pastebin.com/QT5sXEaT). - The fi...
/entry/65002) supported by XTX Markets. The rounds are open for everybody, the rating will be updated

Full text and comments »

Announcement of Codeforces Global Round 5
  • Vote: I like it
  • +3664
  • Vote: I do not like it

3.
By Ari, 6 years ago, In English
Codeforces Global Round 9 <img src="/predownloaded/2e/e2/2ee2f0f95f05aae6ca6f47812dae2dc2aabf277b.png" style="width:200px; float:right; margin: 0 1em 1em 1em"/> Hi! On [contest_time:1375] we will host [contest:1375]. It is the third round of a 2020 series of [Codeforces Global Rounds](/blog/entry/65002). The rounds are open and rated for everybody. The prizes for this round: - 30 best participants get a t-shirt. - 20 t-shirts are randomly distributed among those with ranks between 31 and 500, inclusive. The prizes for the 6-round series in 2020: - In each round top-100 participants get points according to the table. - The final result for each participant is equal to the sum of points he gets in the four rounds he placed the highest. - The best 20 participants over all series get sweatshirts and place certificates. Thanks to XTX, which in 2020 supported the global rounds initiative! The problems of this round were prepared by a team of authors: [user:adamant,2020-07-01], [user:anto...
are open and rated for everybody.

Full text and comments »

Announcement of Codeforces Global Round 9
  • Vote: I like it
  • +2693
  • Vote: I do not like it

4.
By MikeMirzayanov, history, 22 months ago, translation, In English
New Year's Eve Update: Random Problems for Mashups Hello, Codeforces! Only a couple of days remain until 2025. To wrap up the year, I'm bringing an update &mdash; I hope you'll find it useful. Now, you can automatically find and add random problems for your mashup based on a range of criteria and restrictions. The problems are sourced from the archive, and unusual problems are automatically excluded. So, click the "Add random problems" link under the problem list and proceed to the addition form. <center> <img style="zoom:75%;" src="/predownloaded/b9/25/b925e4d00215ff2e408cc81c2629936df72dce38.png"/> </center> Here's what you can do: * Exclude problems that registered mashup participants have solved/attempted/authored (a problem will be excluded if at least one registered participant is familiar with it), * If the mashup belongs to a group (e.g., your training group), exclude all problems from other contests in that group, * Exclude problems with subtasks &mdash; such problems are often interconnected or referenc...

Full text and comments »

  • Vote: I like it
  • +2609
  • Vote: I do not like it

5.
By geranazavr555, history, 6 years ago, translation, In English
Streams on Codeforces Hello everyone! Today Codeforces got support for streams! Thanks [user:tourist,2020-10-21] for the great idea! There are two popular platforms supported: Twitch and YouTube. The opportunity to add streams to Codeforces is open to red participants and by individual invitations for now. We possibly open this opportunity to more users later. The idea is that streamers will be able to announce their streams to the Codeforces audience. To do this, you should add the stream to the site using a special section in your profile. Please, note that when adding a Twitch stream, you just need to specify the URL of your channel, and when adding a YouTube broadcast, its unique short link (URL like youtu.be/...) Shortly before the start of the stream, a notification about the upcoming stream will appear in the sidebar on the right, which will be shown to all site visitors. For example, right now there is a [user:Errichto,2020-10-21]'s stream announcement in the sidebar. ![Streams in ...
Codeforces is open to red participants and by individual invitations for now. We possiblyopen this, add streams to Codeforces is open to red participants and by individual invitations for now. We

Full text and comments »

  • Vote: I like it
  • +2387
  • Vote: I do not like it

6.
By MikeMirzayanov, 6 years ago, In English
Codeforces EDU: β-testing (Now in English!) <img src="/predownloaded/47/86/4786c2ec901c0b5b490794ca6fd5145f0dcdeae3.png" style="float:right; width: 400px; margin: 0 1em 1em 1em"/> Hello Codeforces! In February, in the Russian-language interface, we announced a new educational subsection of the website. It's time to go international! I am pleased to invite you to test the new section, which so far has the working title EDU. I hope that someday EDU will become a real educational hub for fans of programming competitions. It will be great to have in one place the collected educational content with text and video materials, with selected thematic problems. At the moment, its functionality is still under development, and here is the current progress and <i>β</i>-testing preview. Write your comments and suggestions in the comments here. <center style="margin:2.5em;"> <a href="/edu/courses" style="text-decoration:none; font-size:18px; background-color:#01579B; color:white; font-weight:bold; padding:0.5em 1em;">Go to EDU ...

Full text and comments »

  • Vote: I like it
  • +2375
  • Vote: I do not like it

7.
By ahmed_aly, history, 7 years ago, In English
Goodbye A2 Online Judge :( I'm sadly announcing that [a2oj.com](https://a2oj.com/) ([A2 Online Judge](https://www.facebook.com/A2OnlineJudge/)) will be retiring by end of 2019, I'll shut it down at midnight on New Year's Eve. It was something I took care of for about 10 years. I'm really sorry, but I prefer not to explain my reasons, so please don't ask me why I'm doing this, it was hard enough for me to make this decision, and also please don't try to convince me to change my mind. I'd like to say thank you to everyone who used it, and please accept my sincere apologies for shutting it down. If you have something good to say about A2OJ (how you used it or how it helped you in any way), I'd love to read that, please send it to the following email (or in a comment here): [email protected] Also please feel free to take a copy of any data you can access, and if you need some data in a specific format, please send your request to the following email: [email protected] (if the data isn't public, make sure to send f...
different source codes stored in the database. - 261,733 compiled and executed source codes (in 54, . - 1,581,430 submissions collected from other online judges. - 937,658 differentsource codes

Full text and comments »

  • Vote: I like it
  • +1793
  • Vote: I do not like it

8.
By YuukiS, 11 months ago, In English
Good Bye 2025 <div style="overflow:hidden;"> <img src="/predownloaded/a2/4f/a24f8db165991fb983fc766d223782cbf2785f7f.png" style="float:right; width:200px; height:auto; margin-left:50px; margin-right:50px; border-radius:0px;" /> <h2>Merry Christmas, Codeforces! &#127876; &#127876; &#127876;</h2> <p> We are glad to invite you to take part in [contest:2178], which will start on [contest_time:2178]. You will be given <b>9 problems</b> and <b>3 hours</b> to solve them. <b>At least one problem will be interactive</b>, so please make sure to read the <a href="https://codeforces.me/blog/entry/45307">guide for interactive problems</a> before the contest. This round is open and rated for everyone. </p> <p> Problems are authored by [user:conqueror_of_tourist,2025-12-25], [user:twosquares,2025-12-25], and [user:YuukiS,2025-12-25]. </p> <p> We would like to thank: </p> </div> <div style="clear:both;"></div> - [user:Error_Yuan,2025-12-...
/blog/entry/45307">guide for interactive problems before the contest. This round isopen and rated, ://codeforces.com/blog/entry/45307">guide for interactive problems before the contest. This round isopen

Full text and comments »

Announcement of Good Bye 2025
  • Vote: I like it
  • +1689
  • Vote: I do not like it

9.
By FieryPhoenix, 6 years ago, In English
Codeforces Global Round 14 Hi! On [contest_time:1515], we will host [contest:1515]. **<img src="/predownloaded/2e/e2/2ee2f0f95f05aae6ca6f47812dae2dc2aabf277b.png" style="width: 200.0px;float: right;margin: 0 1.0em 1.0em 1.0em;max-width: 100.0%;max-height: 100.0%;">** This is the second round of the 2021 series of [Codeforces Global Rounds](https://codeforces.me/blog/entry/65002). The rounds are open and rated for everybody. The prizes for this round: - 30 best participants get a t-shirt. - 20 t-shirts are randomly distributed among those with ranks between 31 and 500, inclusive. The prizes for the 6-round series in 2021: - In each round top-100 participants get points according to the [table](https://pastebin.com/QT5sXEaT). - The final result for each participant is equal to the sum of points he gets in the four rounds he placed the highest. - The best 20 participants over all series get sweatshirts and place certificates. Thanks to XTX, which in 2021 supported the global rounds i...
[Codeforces Global Rounds](https://codeforces.me/blog/entry/65002). The rounds areopen and rated for, /blog/entry/65002). The rounds are open and rated for everybody.

Full text and comments »

Announcement of Codeforces Global Round 14
  • Vote: I like it
  • +1595
  • Vote: I do not like it

10.
By MikeMirzayanov, 6 years ago, In English
Codeforces New Feature: Rewrite Statements in Mashups Hello Codeforces! There is something new for you. It seems that now it will be easier to reuse problems from the archive for educational and other purposes. As you know, problems from past Codeforces rounds can be added to <a href="https://codeforces.me/blog/entry/10099">mashups</a> simply by their codes of the form like <code>1234D</code> (contest ID + problem letter). I myself regularly used this when I taught at Saratov University &mdash; it was very convenient to prepare trainings: problems have expected complexity and topics, there are Russian and English statements, you can see the analysis and many solutions. Because of hacks and uphacks, problems in the archive usually have strong tests. Almost all of them are well-prepared. In addition, with the help of <a href="https://codeforces.me/blog/entry/21912">user lists</a>, you can easily pick up problems for a group of students that they did not solve. <img src="/predownloaded/2f/ec/2fecbf1f7e7a8f8655f0f74576fd1f6dbbc2307...

Full text and comments »

  • Vote: I like it
  • +1666
  • Vote: I do not like it

11.
By Error_Yuan, history, 3 years ago, In English
Goodbye 74TrAkToR + Problem A~E: The problems themselves are good and typical A~E. Indeed I like problem D. The pretest for A is a bit weak, and it's not a big problem yet. + Problem F: The problem has an origin. :) See the link: [click](https://www.luogu.com.cn/problem/P9394). The problem in contest is only a weakened version of the one in Luogu. + Problem G: It's said that our great coordinator had not proved the time complexity of the intended solution is correct :) If the authors did, please share it in the editorial. (although this problem is completely beyond my ability :) ) + Problem H: Oh dear [user:74TrAkToR,2023-12-30], could you please OEIS the sequence before you use the "several-integer-input" problem in rounds next time? Anyone who copied the first example and opened [https://oeis.org/A286331](https://oeis.org/A286331) could quickly get the formula. And the problem itself is not so hard imo. Anyway, it should not be used in contest, especially for the last problem. For me pers...

Full text and comments »

  • Vote: I like it
  • +1597
  • Vote: I do not like it

12.
By MikeMirzayanov, 37 hours ago, In English
Codeforces Round 1134 (Div. 4) Hello Codeforces! I am glad to invite you to [contest:2290], which will take place on [contest_time:2290]. After quite a long break, I have taken up problem setting again — this time working together with AI agents. For me, this is an experiment in getting back into problem writing, and we will see together how successful AI turns out to be as a partner in this work. I am looking forward to seeing both Div. 4 participants competing officially and everyone else joining out of competition! <div style="height:1em;"></div> <spoiler summary="Why I decided to author this round (a bit of lyrics and rambling)"> Yes, I am dictating these words into my phone right now, to put them into shape for you a bit later. We live in an amazing time when so many things are changing. I have been programming for more than 25 years now, and throughout almost all of this time I wrote code every day and solved problems every day. At first, these were mostly programming contest problems — ...
an incorrect submission; - 12-hour phase of open hacks after the end of the round (hacks do not give, ; - 12-hour phase of open hacks after the end of the round (hacks do not give additional points

Full text and comments »

  • Vote: I like it
  • +1505
  • Vote: I do not like it

13.
By MikeMirzayanov, 9 years ago, translation, In English
New: Diagnostics of Solutions in C++ <img src = "/predownloaded/b5/d2/b5d246ffc32dfe82c3cbac77d1898c5fcb62fa57.jpg" style = "float: right; margin: 0 1em 1em 1em;"/> Hello! I am pleased to report that two rounds of Codeforces have gone quite well in terms of the work of Codeforces, I am very glad about it. These <s>days</s> nights I spent in a profiler, fixing the code, researching the settings of MariaDB. In addition, I managed to allocate several hours on Sunday (to be honest, until Monday morning) to finish the long-planned innovation. Meet, diagnostics of solutions in C++! Many Codeforces visitors are already tired of the questions of less experienced participants: "Why does my solution not work on some test on the Codeforces servers, if I locally launch it and it works correctly? You have the wrong compiler/servers!" In 99% of cases this is an example of <a href ="https://en.wikipedia.org/wiki/Undefined_behavior">undefined behavior</a> in a program. In other words, the program contains mistakes that, du...
and even the source code line. If the diagnostics are not displayed, then at least one condition, cause of the mistake and even the source code line. If the diagnostics are not displayed, then at least

Full text and comments »

  • Vote: I like it
  • +1719
  • Vote: I do not like it

14.
By Endagorion, history, 6 years ago, In English
Codeforces Global Round 8 <img src="/predownloaded/2e/e2/2ee2f0f95f05aae6ca6f47812dae2dc2aabf277b.png" style="width:200px; float:right; margin: 0 1em 1em 1em"/> Hi! On [contest_time:1368] we will host [contest:1368]. It is the second round of a 2020 series of [Codeforces Global Rounds](/blog/entry/65002). The rounds are open and rated for everybody. The prizes for this round: - 30 best participants get a t-shirt. - 20 t-shirts are randomly distributed among those with ranks between 31 and 500, inclusive. The prizes for the 6-round series in 2020: - In each round top-100 participants get points according to the [table](https://pastebin.com/QT5sXEaT). - The final result for each participant is equal to the sum of points he gets in the four rounds he placed the highest. - The best 20 participants over all series get sweatshirts and place certificates. Thanks to XTX, which in 2020 supported the global rounds initiative! Problems for this round are set by me. Thanks a lot to the coordin...
rounds are open and rated for everybody.

Full text and comments »

Announcement of Codeforces Global Round 8
  • Vote: I like it
  • +1315
  • Vote: I do not like it

15.
By platelet, 3 years ago, In English
CodeTON Round 5 (Div. 1 + Div. 2, Rated, Prizes!) **Note the unusual start time of the round.** Hello, Codeforces! Now that Gaokao is over, we are very glad to invite you to participate in [contest:1842], which will start at [contest_time:1842]. You will be given **9 problems** and **3 hours** to solve them. The round will be rated for everyone. All problems are written and prepared by [user:Gary2005,2023-06-21], [user:Asuka,2023-06-21], [user:Crying,2023-06-21], [user:sjcsjcsjc,2023-06-21], [user:MonkeyKing,2023-06-21], [user:DerekFeng,2023-06-21], [user:KbltQaQ,2023-06-21], [user:ShmilyTY,2023-06-21] and me. Statements and editorials will be available in Chinese (Simplified) after the contest. We would like to give our sincere thanks to: - [user:errorgorn,2023-06-21] for his wonderful coordination! - [user:Alexdat2000,2023-06-21] for translating problem statements. - [user:gyh20,2023-06-21], [user:wangziji,2023-06-21], [user:flowerletter,2023-06-21], [user:themoon,2023-06-21], [user:qiuzx,2023-06-21], [user:Gezh...
Foundation](https://ton.org/) team, are pleased to support CodeTON Round 5._ _TheOpen Network (TON) is, _The Open Network (TON) is a fully decentralized layer-1 blockchain designed to onboard billions of

Full text and comments »

  • Vote: I like it
  • +1345
  • Vote: I do not like it

16.
By McDic, history, 7 years ago, In English
Codeforces Round #633 **내가 돌아왔다!** (Hello, Codeforces!) I am thrilled to introduce you to [Codeforces Round #633](https://codeforces.me/contests/1338,1339). Followings are basic information: - This contest will take place on [contest_time:1338]. - The round is **rated for all participants** who can understand this announcement. There will be two divisions. - There are **5 problems** in each division and you will have **2 hours** to solve it. - Score distribution will be announced later. Followings are contributors: - **Authors**: [user:McDic,2020-04-10] (All Div.2 problems and Div.1 D), [user:tzuyu_chou,2020-04-10] (Div.1 E) - **Coordinator**: [user:antontrygubO_o,2020-04-10] - **Testers**: - **Phase 1** (When this round was supposed to be Div.2): [user:dorijanlendvaj,2020-04-10], [user:SoulTch,2020-04-10], [user:pajenegod,2020-04-10], [user:AryaPawn,2020-04-10], [user:Rahul,2020-04-10], [user:mcdx9524,2020-04-10], [user:300iq,2020-04-10], [user:Nemo,2020-04-10], [user:tfg,2020-04-10]...

Full text and comments »

  • Vote: I like it
  • +1622
  • Vote: I do not like it

17.
By AquaMoon, 4 years ago, In English
CodeTON Round 2 Hello, Codeforces! A wonderful summer holiday! After College Entrance Examination, we are extremely delighted to invite you to our second round, [contest:1704], which will be held on [contest_time:1704]. **Note the unusual start time of the round.**You are given **8 problems** and **2.5 hours** to solve them. All problems were written and prepared by [user:Cirno_9baka,2022-07-23], [user:CoupDeGrace,2022-07-23], [user:Heltion,2022-07-23], [user:ODT,2022-07-23], [user:Yakumo_Ran,2022-07-23], [user:farmerj,2022-07-23], [user:flowerletter,2022-07-26], [user:izlyforever,2022-07-23], [user:kuangbin,2022-07-23], [user:mejiamejia,2022-07-23], [user:ugly2333,2022-07-23] and me. Task statements and editorials will also be available in Chinese (Simplified) and Chinese (Traditional) after the contest. We are sincerely thankful for the help provided by: - [user:3.141592653,2022-07-25], [user:emorgan5289,2022-07-25], [user:errorgorn,2022-07-25], [user:SevenDawns,2022-07-25], [user:pr...
/16830/Schinese_Statements_mod.mhtml) is available.(please download it and open it with edge)**, /download/16830/Schinese_Statements_mod.mhtml) is available.(please download it andopen it with edge, _The Open Network (TON) is a fully decentralized layer-1 blockchain designed to onboard billions of

Full text and comments »

  • Vote: I like it
  • +1308
  • Vote: I do not like it

18.
By Radewoosh, history, 8 years ago, In English
Blogewoosh #6 Hello, codeforces! Sorry for the long break, but the last weeks of holidays and the first weeks of academic year took my attention. I hope today's trick will make you forgive me. :P I invented this trick a few years ago, but for sure I wasn't first, and some of you already know it. Let's consider the following **interactive** task. There are $n$ ($1 \leq n \leq 10^5$) hidden integers $a_i$, each of them from range $[1, 10^{18}]$. You are allowed to ask at most $103000$ queries. In one query you can choose two integers $x$ and $y$ ($1 \leq x \leq n, 1 \leq y \leq 10^{18}$) and ask a question ''Is $a_x \geq y$?'' The task is to find the value of the greatest element in the hidden array. The checker **isn't** adaptive. Unfortunately, this task is only theoretical, and you cannot solve it anywhere, but it'll turn out, that solution can be handy in many other, much more complicated problems. [cut] $ $ Even beginners should be able to quickly come up with a solution which ask...
in the time limit. I decided to check if current ''source'' will improve my current result and if, this source, and then we print the maximum of them. Looks familiar? The most eye-catching, we do the binary search to find the highest possible result from this source, and then we print the

Full text and comments »

  • Vote: I like it
  • +1075
  • Vote: I do not like it

19.
By Monogon, history, 6 years ago, In English
Codeforces Global Round 12 <img src="/predownloaded/2e/e2/2ee2f0f95f05aae6ca6f47812dae2dc2aabf277b.png" style="width:200px; float:right; margin: 0 1em 1em 1em"/> ¡Buenos días! (That's Spanish for "what's up homies") On [contest_time:1450] we will host [contest:1450]. It is the sixth round of a 2020 series of [Codeforces Global Rounds](/blog/entry/65002). The rounds are open and rated for everybody. The prizes for this round: - 30 best participants get a t-shirt. - 20 t-shirts are randomly distributed among those with ranks between 31 and 500, inclusive. The prizes for the 6-round series in 2020: - In each round top-100 participants get points according to the table. - The final result for each participant is equal to the sum of points he gets in the four rounds he placed the highest. - The best 20 participants over all series get sweatshirts and place certificates. Thanks to XTX, which in 2020 supported the global rounds initiative! The problems were written and prepared by smart Cu...
[Codeforces Global Rounds](/blog/entry/65002). The rounds are open and rated for everybody. The prizes, are open and rated for everybody.

Full text and comments »

Announcement of Codeforces Global Round 12
  • Vote: I like it
  • +1239
  • Vote: I do not like it

20.
By MikeMirzayanov, 3 years ago, In English
Codeforces Round 923 (Div. 3) Gamarjoba, Codeforces! On [contest_time:1927] will start [contest:1927], the next Codeforces round for the Div.3. Lately, I've been coming up with problem ideas less frequently, but I don't want to lose this skill. Welcome to the round where all problems are my own creation! I hope you'll enjoy them. A huge thank you to [user:Vladosiya,2024-02-05] for preparing the majority of problems in Polygon. Also, thanks to [user:pashka,2024-02-05] and [user:KAN,2024-02-06] for helping with the discussion of problem ideas. Thank you very much [user:74TrAkToR,2024-02-05], [user:CLown1331,2024-02-05], [user:EternalAlexander,2024-02-05], [user:Jostic11,2024-02-05], [user:Killever,2024-02-05], [user:KoT_OsKaR,2024-02-05], [user:LoveWX,2024-02-05], [user:MADE_IN_HEAVEN,2024-02-05], [user:dan_dolmatov,2024-02-05], [user:jnmtz111__,2024-02-05], [user:pedrolino,2024-02-05], [user:theRealChainman,2024-02-05], [user:yorky,2024-02-05] for testing the round. As usual for the Div.3 rounds: ...
is rated for participants with ratings up to 1600. * After the round, there will be a 12-houropen

Full text and comments »

  • Vote: I like it
  • +1435
  • Vote: I do not like it

21.
By SecondThread, 13 months ago, In English
Meta Hacker Cup 2025 Schedule Meta Hacker Cup 2025 ================== Meta Hacker Cup is back! We’re excited to announce our schedule for our 2025 season, kicking off on October 10th! - Practice Round: [Fri. October 10th, 10am Pacific (120 hours, 5 days)](https://www.timeanddate.com/worldclock/fixedtime.html?msg=Meta+Hacker+Cup+Practice+Round&iso=20251010T10&p1=234)* - Round 1: [Sat. October 18th, 10am Pacific](https://www.timeanddate.com/worldclock/fixedtime.html?msg=Meta+Hacker+Cup+Round+1&iso=20251018T10&p1=234&ah=3) (3 hours) - Round 2: [Sat. November 1st, 10am Pacific](https://www.timeanddate.com/worldclock/fixedtime.html?msg=Meta+Hacker+Cup+Round+2&iso=20251101T10&p1=234&ah=3) (3 hours) - Round 3: [Sat. November 15th, 10am Pacific](https://www.timeanddate.com/worldclock/fixedtime.html?msg=Meta+Hacker+Cup+Round+3&iso=20251115T10&p1=234&ah=3) (3 hours) - Finals: [Sat. December 13th, 6am Pacific](https://www.timeanddate.com/worldclock/fixedtime.html?msg=Meta+Hacker+Cup+Finals&iso=20251213T06&p1=234&ah=4...
). Registration will open **Friday, October 3rd**. [Register here](https://www.facebook.com, **Update:** Registration is now open -- [Register here](https://www.facebook.com/codingcompetitions, /hacker-cup). Registration will open **Friday, October 3rd**. [Register here](https, Additionally, we have an open invitation to companies developing AI to compete in our AI track

Full text and comments »

  • Vote: I like it
  • +1057
  • Vote: I do not like it

22.
By Um_nik, history, 4 years ago, In English
Unimportant Um_nik Update Hello Codeforces! I have some big news. I am trying to fight depression and live a fuller life. That includes some self-realization, maybe even (I don't even want to think about it) a job. I love cp, and I love teaching, and I know I already tried that, but I believe that this is the way. With the help of my wife, I started to work on some related projects, and today we want to share them with the world. All of them are in the early stages, but we set a hard deadline for March 1, so... Um ================== Um... I am starting a series of educational YouTube videos / selected problems. Every episode of Um is focused on one problem. I will explain how to solve this problem and talk about some related concepts. The idea is to show off some cool concepts using real problems. The kicker: the problem is made public at least a week before the episode airs. So you can use Um as a source of problems. I will try to choose nice problems that highlight some ideas, and problems ...
as a source of problems. I will try to choose nice problems that highlight some ideas, and problems

Full text and comments »

  • Vote: I like it
  • +1048
  • Vote: I do not like it

23.
By tourist, 4 years ago, translation, In English
Codeforces Round #844 (Div. 1 + Div. 2) Hello! Welcome to the [contest:1782] that will start on [contest_time:1782]. It will be a combined rated round for both divisions and open to everyone. This round is a mirror of VK Cup 2022 Elimination — annual programming championship for Russian-speaking competitors organized by VK. VK Cup [started in 2012](https://codeforces.me/vkcup2012) and has grown to be a five-track competition in competitive programming, Mobile, ML, Go, and JavaScript. All the problems are authored and prepared by me. Thanks to [user:KAN,2023-01-13], [user:errorgorn,2023-01-13], [user:lperovskaya,2023-01-13], [user:dario2994,2023-01-15], [user:Monogon,2023-01-15], [user:Arpa,2023-01-15] for making this round better. You will be given 8 problems and 3 hours to solve them. **UPD**: [Editorial](https://codeforces.me/blog/entry/111783) Congratulations to the winners: 1. [user:orzdevinwang,2023-01-24] 2. [user:noimi,2023-01-24] 3. [user:Radewoosh,2023-01-24] 4. [user:gamegame,2023-01-24] ...
round for both divisions and open to everyone.

Full text and comments »

  • Vote: I like it
  • +1287
  • Vote: I do not like it

24.
By Um_nik, history, 5 years ago, In English
How to practice Competitive Programming [Um_nik version] CP is about solving problems fast. And as absurd as it may sound, I believe that <span style="color:blue">SOLVE</span> and <span style="color:red">FAST</span> are very different and almost independent parts, and you need to practice them separately. Let’s look at some <span style="color:red">contest</span>, like a CodeForces round. For the sake of simplicity let’s assume that every problem has some *difficulty*, which is a numerical value denoting how hard it is, bigger values correspond to harder problems (it is not true, but it is an ok-ish approximation, at least if we consider subjective difficulty for a fixed person). Contests are made for a wide range of participants, and problemsetters strive to make contests interesting for a wide range of participants, which means having a *smooth difficulty gradient*. Well... as smooth as it is possible with 5-6 problems. <spoiler summary="Graph 1"> ![ ](https://s3.us-west-2.amazonaws.com/secure.notion-static.com/677e0ae2-a8df-4874-aff...
different problem, return to it after a month or so. My usual approach was to open 10-15 problems

Full text and comments »

  • Vote: I like it
  • +1117
  • Vote: I do not like it

25.
By zimpha, 6 years ago, In English
List of All Open Cup Contests Open Cup has very high quality problems. I made a list for all the contests containing the standings, sources, upsolving links, statements and discuss blog in codeforces. Some materials and links of old opencup contests are missing, maybe [user:snarknews,2020-11-10] could help to fill these entries. I will update the list when new opencup stages published. Note: most of the upsolving links need the logins for yandex.contest or opentrains. ## XXI Open Cup named after E.V. Pankratiev | # | Contest | Upsolving | Materials | |:--:|:------------|:--:|:--:| | Stage 1 | [Grand Prix of Eurasia](https://official.contest.yandex.ru/opencupXXI/contest/20063/standings)<br/> [XXI All-Siberian Programming Contest. Online](https://olympic.nsu.ru/files/inet_res_2020_0.pdf) | [baekjoon](https://www.acmicpc.net/category/detail/2403)<br/> [yandex](http://official.contest.yandex.ru/opencupXXI/contest/20063) | [statement](https://yadi.sk/i/dsRvTxbgJ9fDXw) [discuss](https://codeforces.me/blog/...
List of All Open Cup Contests, ## I Open Cup named after E.V. Pankratiev, ## II Open Cup named after E.V. Pankratiev, ## III Open Cup named after E.V. Pankratiev, ## IV Open Cup named after E.V. Pankratiev, ## IX Open Cup named after E.V. Pankratiev, ## V Open Cup named after E.V. Pankratiev, ## VI Open Cup named after E.V. Pankratiev, ## VII Open Cup named after E.V. Pankratiev, ## VIII Open Cup named after E.V. Pankratiev, ## X Open Cup named after E.V. Pankratiev, ## XI Open Cup named after E.V. Pankratiev, ## XII Open Cup named after E.V. Pankratiev, ## XIII Open Cup named after E.V. Pankratiev, ## XIV Open Cup named after E.V. Pankratiev, ## XIX Open Cup named after E.V. Pankratiev, ## XV Open Cup named after E.V. Pankratiev, ## XVI Open Cup named after E.V. Pankratiev, ## XVII Open Cup named after E.V. Pankratiev, ## XVIII Open Cup named after E.V. Pankratiev, ## XX Open Cup named after E.V. Pankratiev, ## XXI Open Cup named after E.V. Pankratiev, &ncup=ocg) [Open Ural FU Championship 2015](https://sp.urfu.ru/urfu/2015/standings.html) | [yandex, &ncup=oci) [8th BSUIR Open Programming Championship. Final](https://codeforces.me/gym/102136, &stg=4&region=main&ncup=oc7) 2010 Southern Russia Open Championship | [e-olymp](https, /> [2012 Southern Russia Open Championship](https://docs.google.com/open?id, /index.cgi?data=macros/stage&stg=7&region=main&ncup=ocd) [2013 Southern Russia Open Championship, /stage&stg=18&region=main&ncup=ocj) [9th BSUIR Open Programming Championship. Final](https, /stage&stg=6&region=main&ncup=oc9) [2011 Southern Russia Open Championship](http://docs.google.com, /standings) [10th KAIST ICPC Mock Competition Open Contest](https://www.acmicpc.net/contest, =3&region=main&ncup=oca) [Open Ural FU Championship 2011](https://sp.urfu.ru/urfu/2011, =macros/stage&stg=5&region=main&ncup=oc6) [Open Ural SU Championship 2009](https://sp.urfu.ru/usu, =main&ncup=oce) [2014 Southern Russia Open Championship](https://drive.google.com/file/d, Open Cup has very high quality problems. I made a list for all the contests containing the

Full text and comments »

  • Vote: I like it
  • +842
  • Vote: I do not like it

26.
By MikeMirzayanov, 3 years ago, In English
Polygon: AI-Powered Automatic Tips Hello, Codeforces! <i>For the new members of the community, I would like to remind you that Polygon (https://polygon.codeforces.com/) is a system developed and maintained by Codeforces for preparing programming problems. It is there that authors and coordinators develop all the problems for the rounds. Moreover, I believe a significant (large?) portion of the problems for other competitions is also developed there: various stages of ICPC, national competitions of different levels, educational problems for various courses, etc. <b>In 2023, more than 50000 problems were prepared in Polygon (only those for which a package was compiled are counted)!</b></i> Large language models are becoming an increasingly integral part of our lives, taking over routine and monotonous tasks. With their help, problems created in Polygon will now have fewer typos and incorrect language constructions. We have recently implemented three features in Polygon to ease routine tasks: * Translati...
Clicking on the review link will open a tool for merging changes.

Full text and comments »

  • Vote: I like it
  • +1190
  • Vote: I do not like it

27.
By Tlatoani, 6 years ago, In English
Codeforces Global Round 10 Hi! <img src="/predownloaded/2e/e2/2ee2f0f95f05aae6ca6f47812dae2dc2aabf277b.png" style="width: 200.0px;float: right;margin: 0 1.0em 1.0em 1.0em;max-width: 100.0%;max-height: 100.0%;"> On [contest_time:1392] we will host [contest:1392]. This is the fourth round of a 2020 series of [Codeforces Global Rounds](https://codeforces.me/blog/entry/65002). The rounds are open and rated for everybody. The prizes for this round are as follows: - The top 30 participants get a t-shirt. - 20 t-shirts are randomly distributed among those with ranks between 31 and 500, inclusive. The prizes for the 6-round series in 2020 are as follows: - In each round, the top 100 participants get points according to [this table](https://pastebin.com/QT5sXEaT). - The final result for each participant is equal to the sum of the points they got in the four rounds where they placed the highest. - The top 30 participants over all series get sweatshirts and place certificates. Thanks to XTX for sup...
Global Rounds](https://codeforces.me/blog/entry/65002). The rounds are open and rated for everybody, /entry/65002). The rounds are open and rated for everybody.

Full text and comments »

Announcement of Codeforces Global Round 10
  • Vote: I like it
  • +1170
  • Vote: I do not like it

28.
By Ra16bit, history, 5 years ago, In English
Competitive Programming Hall of Fame — cphof.org Hi Codeforces! Today I'd like to introduce the new [Competitive Programming Hall of Fame](https://cphof.org) project that is available at [cphof.org](https://cphof.org) ![ Logo ](/predownloaded/12/35/1235b4fcce22b33f83cf26221d889087e06d8592.png) #### Background A long time ago I've noticed that there is no single source of information with the results of previously held large programming competitions. Moreover, plenty of older championships don't maintain their websites anymore, and it becomes hard or even impossible to find any details about them, which is pretty sad. So I've decided to create [Competitive Programming Hall of Fame](https://cphof.org). #### About the project Competitive Programming Hall Of Fame is a project created to preserve the history of international championships in competitive programming. This website collects the results of the final stages for both worldwide and regional contests. By international championship we mean a contest consisting ...
noticed that there is no single source of information with the results of previously held large, A long time ago I've noticed that there is no single source of information with the results of

Full text and comments »

  • Vote: I like it
  • +1176
  • Vote: I do not like it

29.
By Qingyu, 16 months ago, In English
About the Universal Cup, the Semifinals, and myself... Hey'all! This gonna be a long post, so let me put an important TLDR here first: we are going to host **The 3rd Universal Cup Semifinals**, which will take place on August 24, 2025 **online**, at [11:00 (UTC)](https://www.timeanddate.com/worldclock/fixedtime.html?msg=The+3rd+Universal+Cup+Semifinals&iso=20250824T19&p1=33&ah=5). This contest will be a part of our Finals Team Selection, which the detailed rules and announcements will be published later next week. --- Now for some extra context, if you're interested. Last week, we hosted the [last online stage](https://codeforces.me/blog/entry/143954) of The 3rd Universal Cup. After that, I posted a [feedback form](https://docs.google.com/forms/d/1g5Txhiirh_lRsvGfkYWRozu0WDDGK31IAXjB7VgeVoM/edit) on our discord server. I received lots of thoughtful responses (P.S — it's still open, so feel free to fill it out if you haven't yet!). I've read through all the feedback, and I'd like to share a few thoughts. ### On the Number...
(P.S — it's still open, so feel free to fill it out if you haven't yet!)., and around 20 in regular Open Cup seasons. Unlike 2-3 hour CF rounds, these are 5-hour contests for, decent number of new sources, we will consider to open the UCup Olympiad Track. But for now, it’s, more, but I'm always open to suggestions!, Regarding the extra early start window, this should feel familiar if you've participated inOpen

Full text and comments »

  • Vote: I like it
  • +814
  • Vote: I do not like it

30.
By MikeMirzayanov, 5 years ago, In English
C++20 Is Released Hello, Codeforces. Please, welcome c++20 support on Codeforces. Yes, it is 64-bit. Thanks to Brecht Sanders: I used his distribution GCC-11.2.0-64 from https://winlibs.com/. If you have installed [PBOX](http://pbox.me/packages), you can add this compiler with the line `pbox install gcc11-64-winlibs`. Probably, a good idea is to add `C:\Programs\gcc11-64-winlibs\bin` into the PATH. More about PBOX you can read [here](https://codeforces.me/blog/entry/18274). I use the compilation command line similar to other GCC installations: `g++ -Wall -Wextra -Wconversion -static -DONLINE_JUDGE -Wl,--stack=268435456 -O2 -std=c++20 <source>`. The only differences are `-std=c++20` and `-Wall -Wextra -Wconversion` (I plan to use somehow such warnings in Polygon to suggest fixes in uploaded files). Now you can use c++20 in your solutions. I'm not sure there are many features useful in competitive programming. Probably, I'm wrong. For example, now you can write `vector v{vector{1, 2}};` inste...
-Wconversion -static -DONLINE_JUDGE -Wl,--stack=268435456 -O2 -std=c++20 < source>`. The only differences are, -Wl,--stack=268435456 -O2 -std=c++20 <source>`. The only differences are `-std=c++20` and `-Wall

Full text and comments »

  • Vote: I like it
  • +1524
  • Vote: I do not like it

31.
By lotusblume, 15 months ago, In English
Worst-Case Graphs for Maximum Flow Algorithms Maximum flow algorithms are known to perform significantly better in practice than their worst-case time complexities would suggest. So in this blog, I will present graphs on which the following maximum flow algorithms actually achieve their worst-case running time: | Algorithm | Time Complexity | | ----------------------- | ------------------------------ | | Ford-Fulkerson with DFS | $\mathcal{O}\big(m^2 \cdot U)$ | | Edmonds-Karp | $\mathcal{O}\big(n \cdot m^2\big)$ | | Dinic | $\mathcal{O}\big(n^2 \cdot m\big)$ | | DFS with Scaling | $\mathcal{O}\big(m^2 \cdot \log(U)\big)$ | | Dinic with Scaling | $\mathcal{O}\big(n \cdot m \cdot \log(U)\big)$ | | Most Improving Augmenting Paths | $\mathcal{O}\big(m \cdot \log(U) \cdot (m + n \cdot \log(n))\big)$ | | FIFO Preflow Push | $\mathcal{O}\big(n^3\big)$ | | Highest-Label Preflow Push | $\mathcal{O}\big(n^2 \cdot \sqrt{m}\big)$ | Here and in the rest of this blog: - $n =$ number of vertices, ...
/e4db74d6a8c0500c497ad39f1a20d957acbfe59e.svg) The source will push an excess of value $w^2$ into $a_1$. Which will then be split into $w, Ideally we want to have more than one source vertex. Initially one source vertex should send a flow, The source will push an excess of value $w^2$ into $a_1$. Which will then be split into $w$ pushes, We can actually simulate this behavior of having multiple sources. The real source $s$ will be

Full text and comments »

  • Vote: I like it
  • +927
  • Vote: I do not like it

32.
By MikeMirzayanov, 4 years ago, In English
Codeforces Sponsored by TON! <img src="/predownloaded/12/a0/12a02d5f16863f9f45bba4c6cd4224f0f2178b94.png" style="float:right; margin: 0 1em 1em 1em; width: 400px;"/> Hello, Codeforces. We have exciting news! Look at the logo. See the changes? Yes, we are happy to announce our new sponsor and partner – the TON Foundation! We appreciate their support! The Open Network (TON) is a fully decentralized layer-1 blockchain designed by Telegram to onboard billions of users. The TON Foundation is aimed to further develop and advance the TON Blockchain and its related products for a mass audience. Andrew Rogozov, founding member at the TON Foundation, says, "<i>We strongly believe in the idea of competitive programming itself, because it is in the TON Blockchain DNA.</i>" The TON Blockchain protocol was designed by Nikolai Durov — who is a two-time ICPC world champion, a three-time IMO gold medalist, a multiple IOI medalist, and a co-founder of Telegram — and other winners of international competitions...
Foundation! We appreciate their support! The Open Network (TON) is a fully decentralized layer-1, The Open Network (TON) is a fully decentralized layer-1 blockchain designed by Telegram to onboard

Full text and comments »

  • Vote: I like it
  • +1188
  • Vote: I do not like it

33.
By Errichto, 3 months ago, In English
Petition to Display Color of Max Rating In Codeforces, the nickname color depends on the current rating. I propose to use the historical max rating instead. The nickname color is not only a bragging right, but also a good heuristic when choosing which blogs to open in "Recent actions", and which posts to read when scrolling through many comments. Here's why I think that we should use max rating: 1. It's less random. 2. Current rating is nowadays more affected by AI cheaters. 3. There will be less incentive to create a second account when you're afraid to drop below some threshold. 4. It will make recognizing others easier (because the color won't change often). 5. I don't want to be orange.
blogs to open in "Recent actions", and which posts to read when scrolling through many comments. Here's, when choosing which blogs to open in "Recent actions", and which posts to read when scrolling through

Full text and comments »

  • Vote: I like it
  • +1459
  • Vote: I do not like it

34.
By dario2994, 6 years ago, In English
Codeforces Global Round 11 <img src="/predownloaded/2e/e2/2ee2f0f95f05aae6ca6f47812dae2dc2aabf277b.png" style="width:200px; float:right; margin: 0 1em 1em 1em"/> Hi! On [contest_time:1427] we will host [contest:1427]. This is the fifth round of the 2020 series of [Codeforces Global Rounds](https://codeforces.me/blog/entry/65002). The rounds are open and rated for everybody. The prizes for this round are as follows: - 30 best participants get a t-shirt. - 20 t-shirts are randomly distributed among those with ranks between 31 and 500, inclusive. The prizes for the 6-round series in 2020: - In each round top-100 participants get points according to the [table](https://pastebin.com/QT5sXEaT). - The final result for each participant is equal to the sum of points he gets in the four rounds he placed the highest. - The best 20 participants over all series get sweatshirts and place certificates. Thanks to XTX, which in 2020 supported the global rounds initiative! Problems for this round ar...
/blog/entry/65002). The rounds are open and rated for everybody.

Full text and comments »

Announcement of Codeforces Global Round 11
  • Vote: I like it
  • +1025
  • Vote: I do not like it

35.
By ATSTNG, history, 7 years ago, In English
[Tutorial] Matroid intersection in simple words **[This article is also available in [Russian](https://codeforces.me/blog/entry/69287?locale=ru)]** Hello, CodeForces. I think that matroids are beautiful and powerful concept, however, not really well known in competitive programming. I’ve discovered matroids at 2019 Petrozavodsk Winter Training Camp. There was a problem that clearly cannot be solved using usual techniques I knew, editorial for this problem was just these three words “just matroid intersection”. Back then it took me more than 2 days of upsolving to find all the information and details I need and implement solution that gets Accepted on this. And it took way longer to actually understand why does it work and exactly how does it work. (I still hesitate in some details.) Of course, it is not hard to google up all the definitions and some related articles, but in my opinion they all are focused more on mathematical part of theory, strict proofs in some not really obvious but short ways, and observing only ke...

Full text and comments »

  • Vote: I like it
  • +904
  • Vote: I do not like it

36.
By tourist, 6 years ago, In English
touristreams are back! 006: SNSS 2020 R1, and more It's this time of the year again! Tune in at [twitch.tv/the__tourist](https://twitch.tv/the__tourist) at around [21:45 MSK, 21 Aug 2020](https://www.timeanddate.com/worldclock/fixedtime.html?msg=touristream+006&iso=20200821T2145&p1=3396) to watch me solving [SnarkNews Summer Series 2020 Round 1](https://contest.yandex.com/snss2020/contest/19320/enter) live! First I will do the round competitively without much interaction, and I'll be up for discussing the problems on stream afterwards. SnarkNews Winter/Summer Series (SNWS/SNSS) is organized by [user:snarknews,2020-08-19] yearly and consists of 5 rounds. Each round is a virtual 6-problem 80-minute contest open for 10 days. The series is open to all, but problem statements are in Russian only. Unlike last series, I'll be reading problem statements automatically translated to English on stream. To make the stream more fun and for easier understanding of what will be going on, you're welcome to do the round yourself beforehand! If...
consists of 5 rounds. Each round is a virtual 6-problem 80-minute contest open for 10 days. The

Full text and comments »

  • Vote: I like it
  • +747
  • Vote: I do not like it

37.
By star_xingchen_c, 6 years ago, In English
Codeforces Global Round 13 Hello Codeforces! On [contest_time:1491] we will host [contest:1491]. **<img src="/predownloaded/2e/e2/2ee2f0f95f05aae6ca6f47812dae2dc2aabf277b.png" style="width: 200.0px;float: right;margin: 0 1.0em 1.0em 1.0em;max-width: 100.0%;max-height: 100.0%;">** It is the first round of a 2021 series of [Codeforces Global Rounds](https://codeforces.me/blog/entry/65002). The rounds are open and rated for everybody. The prizes for this round: - 30 best participants get a t-shirt. - 20 t-shirts are randomly distributed among those with ranks between 31 and 500, inclusive. The prizes for the 6-round series in 2021: - In each round top-100 participants get points according to the [table](https://pastebin.com/QT5sXEaT). - The final result for each participant is equal to the sum of points he gets in the four rounds he placed the highest. - The best 20 participants over all series get sweatshirts and place certificates. Thanks to XTX, which in 2021 supported the global rounds ...
/entry/65002). The rounds are open and rated for everybody.

Full text and comments »

Announcement of Codeforces Global Round 13
  • Vote: I like it
  • +1092
  • Vote: I do not like it

38.
By Mangooste, history, 5 years ago, translation, In English
Codeforces Global Round 19 Hello, Codeforces! (づ。◕‿‿◕。)づ ❤ On [contest_time:1637] we will host [contest:1637]. **<img src="/predownloaded/2e/e2/2ee2f0f95f05aae6ca6f47812dae2dc2aabf277b.png" style="width: 200.0px;float: right;margin: 0 1.0em 1.0em 1.0em;max-width: 100.0%;max-height: 100.0%;">** It is the first round of a 2022 series of [Codeforces Global Rounds](https://codeforces.me/blog/entry/65002) supported by XTX Markets. The rounds are open and rated for everybody. The presents for this round: - 30 best participants get a t-shirt. - 20 t-shirts are randomly distributed among those with ranks between 31 and 500, inclusive. The presents for the 6-round series in 2022: - In each round top-100 participants get points according to the [table](https://pastebin.com/QT5sXEaT). - The final result for each participant is equal to the sum of points he gets in the four rounds he placed the highest. - The best 20 participants over all series get sweatshirts and place certificates. The problems w...
/entry/65002) supported by XTX Markets. The rounds are open and rated for everybody.

Full text and comments »

Announcement of Codeforces Global Round 19
  • Vote: I like it
  • +1029
  • Vote: I do not like it

39.
By arsijo, 7 years ago, translation, In English
Codeforces Round 591 (and Technocup — Elimination Round 1) Hi all! This weekend, on [contest_time:1223] we will hold Codeforces Round 591. It is based on problems of Technocup 2020 Elimination Round 1 that will be held at the same time. Technocup is a major olympiad for Russian-speaking high-school students, so if you fall into this category, please register at <a href="https://technocup.mail.ru/">Technocup 2020 website</a> and take part in the Elimination Round. Div. 1 and Div.2 editions are open and rated for everyone. Register and enjoy the contests! The Elimination Round authors are [user:BledDest,2019-10-06], [user:MikeMirzayanov,2019-10-06], [user:Ne0n25,2019-10-06], [user:PikMike,2019-10-06], [user:Roms,2019-10-06], [user:adedalic,2019-10-06] and me. This round would also be not possible without the help of our testers: [user:KAN,2019-10-06], [user:chemthan,2019-10-06], [user:gisp_zjz,2019-10-06], [user:Kallaseldor,2019-10-06], [user:JeffreyHo,2019-10-06], [user:danya.smelskiy,2019-10-06], [user:Juve45,2019-10-06], thank you...
Elimination Round. Div. 1 and Div.2 editions are open and rated for everyone. Register and enjoy the, Div. 1 and Div.2 editions are open and rated for everyone. Register and enjoy the contests!

Full text and comments »

  • Vote: I like it
  • +1254
  • Vote: I do not like it

40.
By errorgorn, 5 years ago, In English
Codeforces Global Round 20 On [contest_time:1672], we will host [contest:1672]. **Note the unusual timing, it is 30 minutes earlier.** <strong><img src="/predownloaded/2e/e2/2ee2f0f95f05aae6ca6f47812dae2dc2aabf277b.png" style="width: 200.0px;float: right;margin: 0 1.0em 1.0em 1.0em;max-width: 100.0%;max-height: 100.0%;"></strong> This is the second round of the 2022 series of [Codeforces Global Rounds](https://codeforces.me/blog/entry/65002). The rounds are open and rated for everybody. The prizes for this round: - 30 best participants get a t-shirt. - 20 t-shirts are randomly distributed among those with ranks between 31 and 500, inclusive. The prizes for the 6-round series in 2022: - In each round top-100 participants get points according to the [table](https://pastebin.com/QT5sXEaT). - The final result for each participant is equal to the sum of points he gets in the four rounds he placed the highest. - The best 20 participants over all series get sweatshirts and place certificates. T...
/blog/entry/65002). The rounds are open and rated for everybody.

Full text and comments »

Announcement of Codeforces Global Round 20
  • Vote: I like it
  • +861
  • Vote: I do not like it

41.
By PinkieRabbit_buster, 3 years ago, In English
PinkieRabbit Cheated in Div. 1 Contest on Apr 27 I am writing to report an incident of cheating by PinkieRabbit during the recent contest 1965 on Codeforces. **PinkieRabbit asked help about problem D from others during the contest,** which is definitely against the contest rules. I have attached the evidence of the cheating behavior in the appendix, please read it. This evidence clearly shows the communications PinkieRabbit had with another person during the contest. It is a contest recording video published after contest by himself. As a former fan of PinkieRabbit, after seeing this video, I was shocked by how dishonest PinkieRabbit was. I believe such actions undermine the integrity of the competition and the platform as a whole. [user:win114514,2024-05-05] cheated by grouping up in contest 1905, finally punished by skipping. Therefore, I respectfully request that Codeforces take appropriate action against PinkieRabbit to maintain the fairness of the contests on Codeforces. He only cheated in one problem this round, so I sugg...

Full text and comments »

42.
By codetiger927, history, 5 years ago, In English
Introducing CF Stonks — A Virtual Stock Market Based on Your CodeForces Rating! **2/11/2023 Update**: There had been a month-long hiatus due to the CF name change magic (and my own laziness oops), but everything has been fixed now :D! However, I know a lot of people have gone inactive due to the month-long market closure, so I am hoping to **relaunch StonksCF** in the near future with some new mechanisms (dividends, automatic algorithm trading, etc.). Let me know if you have any ideas! In the meantime, feel free to continue exploiting the way-over-inflated economy and embrace your inner capitalism >:D **Final Update**: We now have our own **DISCORD SERVER**. Join us for the latest information and engage with the community at [https://discord.gg/AeH2GTwkF5](https://discord.gg/AeH2GTwkF5) All the announcements will be there instead of on this page Greetings Fellow CodeForces users! I am proud to introduce my latest project, [CF Stonks](https://codetiger.me/project/StonksCF) (aka StonksCF), which is a virtual stock market based on your CodeForces rating. ...
Furthermore, all of the source code is public and available on [GitHub here](https://github.com, While the market is open (closed during contests), you can sell/buy other people's stock. Even, open (closed during contests), you can sell/buy other people's stock. Even though this is just a

Full text and comments »

  • Vote: I like it
  • +711
  • Vote: I do not like it

43.
By kostka, 5 years ago, In English
Cheater Report in Global Round 15 In the last contest, both [user:tourist,2021-07-26] and [user:ko_osaga,2021-07-26] copied the author's solution from the problem Matrix from Petrozavodsk Winter Camp 2013 Warsaw U contest: [submission:123723552] and [submission:123727448] respectively. You can easily verify that they didn't write this code themselves by looking at the comments in these solutions (written in Polish). This is **against the Codeforces rules**. According to [this post](https://codeforces.me/blog/entry/8790), we have the following rules: > Solutions and test generators can only use source code completely written by you, with the following two exceptions: > > 1. the code was written and published/distributed before the start of the round, > 2. the code is generated using tools that were written and published/distributed before the start of the round. and > Currently, the only reliable proof is the presence of code on the Internet and the presence of the used edition in the cache of well-kn...
need to add a comment mentioning the original source of the problem and this solution doesn't have, ), we have the following rules: > Solutions and test generators can only use source code completely, > Solutions and test generators can only use source code completely written by you, with the

Full text and comments »

  • Vote: I like it
  • +910
  • Vote: I do not like it

44.
By wangmarui, history, 10 months ago, In English
Hello 2026 Happy new year, Codeforces! We are glad to invite you to take part in [contest:2183], which will start on [contest_time:2183]. You will be given **9 problems** and **3 hours** to solve them. **At least one problem will be interactive**, so please make sure to read the [guide for interactive problems](https://codeforces.me/blog/entry/45307) before the contest. This round is open and rated for everyone. Problems are authored by [user:wangmarui,2025-12-23], [user:Gold14526,2025-12-23], [user:Hoks_,2025-12-23], [user:Neil_Qian,2025-12-23], [user:Network_Error,2025-12-23], [user:jiazhichen844,2025-12-23] and [user:xvchongyv,2025-12-23]. We would like to thank: - [user:Um_Nik,2025-12-23] for pre-reviewing the round. - [user:Proof_by_QED,2025-12-23] for his wonderful coordination. - [user:Alexdat2000,2025-12-23] for Russian translation. - [user:Geothermal,2025-12-23], [user:StarSilk,2025-12-23], and [user:Dominater069,2025-12-23] for nutella testing. - [user:Mindeve...
/blog/entry/45307) before the contest. This round is open and rated for everyone.

Full text and comments »

Announcement of Hello 2026
  • Vote: I like it
  • +1039
  • Vote: I do not like it

45.
By Radewoosh, 3 years ago, In English
I've completed Project Euler It was a beautiful journey full of internet digging, searching for patterns, learning stuff, fighting with formulas on paper, making crazy observations, coming up with brilliant ideas, implementing crazy optimizations, waiting for the programs to finish, suffering when something was wrong, and so on (and each of the mentioned not once not twice took multiple hours). It's been a couple of months since I was left with the last unsolved problem and finally I did it! I didn't give up and I obtained the answer alone, without anyone's help, like in the rest of the problems (I was using only internet sources created before the publication of the problem). I'm writing this blog because I am bursting with joy and I wanted to share it with the community. I highly recommend PE as most of the problems were definitely very high quality (and some were a real pain in the ass, but they still teach how to overcome stuff that you're uncomfortable with). Here's a little souvenir for me: ![ ](/pr...

Full text and comments »

  • Vote: I like it
  • +1099
  • Vote: I do not like it

46.
By -is-this-fft-, history, 5 years ago, In English
[Tutorial] Collection of little techniques #### Introduction There are a number of "small" algorithms and facts that come up again and again in problems. I feel like there I have had to explain them many times, partly because there are no blogs about them. On the other hand, writing a blog about them is also weird because there is not that much to be said. To settle these things "once and for all", I decided to write my own list about about common "small tricks" that don't really warrant a full tutorial because they can be adequately explained in a paragraph or two and there often isn't really anything to add except for padding. This blog is partly inspired by [user:adamant,2022-03-15]'s [blog](48417) from a few years ago. At first, I wanted to mimic adamant's blog structure exactly, but I found myself wanting to write longer paragraphs and using just bolded sentences as section headers got messy. Still, each section is short enough that it would not make much sense to write separate blogs about each of these things. A...
This problem is from Topcoder Open

Full text and comments »

  • Vote: I like it
  • +804
  • Vote: I do not like it

47.
By maomao90, history, 3 years ago, In English
CodeTON Round 7 (Div. 1 + Div. 2, Rated, Prizes!) Hello Codeforces, We are very glad to invite you to participate in [contest:1896], which will start on [contest_time:1896]. You will be given **8 problems** and **2.5 hours** to solve them. The round will be rated for everyone. All the problems are written and prepared by [user:lanhf,2023-11-22], [user:Mike4235,2023-11-22], [user:thenymphsofdelphi,2023-11-22], [user:xuanquang1999,2023-11-22] and me. We would like to give our sincere thanks to: - [user:errorgorn,2023-11-22] for his wonderful coordination! - [user:Alexdat2000,2023-11-22] for translating problem statements. - [user:Um_nik,2023-11-22] and [user:conqueror_of_tourist,2023-11-22] for Legendary Grandmaster testing. - [user:jeroenodb,2023-11-22], [user:Kuroni,2023-11-22], [user:dario2994,2023-11-22] and [user:dreamoon_love_AA,2023-11-22] for International Grandmaster testing. - [user:generic_placeholder_name,2023-11-22], [user:MofK,2023-11-22], [user:minhcool,2023-11-22], [user:dvdg6566,2023-11-22] and [user:mag...
_The Open Network (TON) is a fully decentralized layer-1 blockchain designed to onboard billions of

Full text and comments »

  • Vote: I like it
  • +788
  • Vote: I do not like it

48.
By dario2994, 5 years ago, In English
Codeforces Global Round 15 <img src="/predownloaded/2e/e2/2ee2f0f95f05aae6ca6f47812dae2dc2aabf277b.png" style="width:200px; float:right; margin: 0 1em 1em 1em"/> Hi! On [contest_time:1552] we will host [contest:1552]. This is the third round of the 2021 series of [Codeforces Global Rounds](https://codeforces.me/blog/entry/65002). The rounds are open and rated for everybody. The prizes for this round are as follows: - 30 best participants get a t-shirt. - 20 t-shirts are randomly distributed among those with ranks between 31 and 500, inclusive. The prizes for the 6-round series in 2021: - In each round top-100 participants get points according to the [table](https://pastebin.com/QT5sXEaT). - The final result for each participant is equal to the sum of points he gets in the four rounds he placed the highest. - The best 20 participants over all series get sweatshirts and place certificates. Thanks to XTX, which in 2021 supported the global rounds initiative! Problems for this round ar...
/blog/entry/65002). The rounds are open and rated for everybody.

Full text and comments »

Announcement of Codeforces Global Round 15
  • Vote: I like it
  • +823
  • Vote: I do not like it

49.
By tourist, history, 10 years ago, translation, In English
VK Cup 2017 Round 3 + Codeforces Round #412 -- Tutorial Here is the tutorial of VK Cup 2017 Round 3 and Codeforces Round #412. Enjoy! <spoiler summary="Is it rated?"> [tutorial:807A] <spoiler summary="Code"> ~~~~~ n = int(input()) results = [] for i in range(n): results.append(list(map(int, input().split()))) for r in results: if r[0] != r[1]: print("rated") exit() for i in range(n): for j in range(i): if results[i][0] > results[j][0]: print("unrated") exit() print("maybe") ~~~~~ </spoiler> </spoiler> <spoiler summary="T-Shirt Hunt"> [tutorial:807B] <spoiler summary="More efficient code"> ~~~~~ #include <bits/stdc++.h> using namespace std; int main() { int p, x, y; cin >> p >> x >> y; for (int s = y; ; s++) { if (s % 50 != x % 50) { continue; } bool me = false; int i = s / 50 % 475; for (int j = 0; j < 25; j++) { i = (i * 96 + 42) % 475; if (i + 26 == p) { me = true; ...
- new_cur; cur = new_cur; } bool fail = false; int open = 0; for (int i

Full text and comments »

  • Vote: I like it
  • +570
  • Vote: I do not like it

50.
By zscoder, history, 10 years ago, In English
[Tutorial] Non-trivial DP Tricks and Techniques Hi everyone! Today I want to share some DP tricks and techniques that I have seen from some problems. I think this will be helpful for those who just started doing DP. Sometimes the tutorials are very brief and assumes the reader already understand the technique so it will be hard for people who are new to the technique to understand it. Note : You should know how to do basic DP before reading the post DP + Bitmasks ------------------ This is actually a very well-known technique and most people should already know this. This trick is usually used when one of the variables have very small constraints that can allow exponential solutions. The classic example is applying it to solve the Travelling Salesman Problem in $O(n^{2} \cdot 2^{n})$ time. We let $dp[i][j]$ be the minimum time needed to visit the vertices in the set denoted by $i$ and ending at vertex $j$. Note that $i$ will iterate through all possible subsets of the vertices and thus the number of states is $O(2^{n} \cdo...
are $j$ **open sets** and the total imbalance till now is $k$. Now, we see how to do the state, element. Some of the current sets are **open**, i.e. has a minimum value but is not complete yet (does, 2. We place the current number $a_{i}$ in one of the open groups, but **not close it** : Then, $dp, 3. Open a new group with minimum = $a_{i}$ : Then, $dp[i][j+1][val] += v$., 4. Close an open group by inserting $a_{i}$ in one of them and **close it** : Then, $dp[i][j-1][val, Example Problem : [JOI 2016 Open Contest — Skyscrapers](http://s3-ap-northeast-1, Open and Close Interval Trick ------------------

Full text and comments »

  • Vote: I like it
  • +612
  • Vote: I do not like it

51.
By cjj490168650, history, 4 years ago, In English
[Repost] "Justice may be delayed, but it cannot be absent": New Evidence on NXIST's Cheating Scandal _Original post: [「正义可以迟来但不能缺席」:关于 NXIST 的一些新证据](https://zhuanlan.zhihu.com/p/620297880)_ _Translated by GPT-4 with some adjustment. Please inform me if there are any mistakes._ _All links to the invalid repository have been redirected to the backup repository._ **This article provides a logically complete set of evidence, which does not involve any non-public internet resources, regarding the "suspected cheating" incident involving the ICPC Yinchuan Station and ICPC Shenyang Station in 2021. By discovering the suspected GitHub account ([NaokiLH](https://github.com/NaokiLH), renamed to https://github.com/brokenTarget) of a team member from Ningxia Institute of Science and Technology (NXIST) TS 1 team, Lan Hao, two years ago, and by mining and analyzing the commit records of his algorithm competition repo, we have obtained direct evidence that at least 4 questions from the 2021 Yinchuan regional contest set and at least 6 questions (including scrapped questions) from the 2021 Sh...
participant), we obtained a very strong piece of evidence (and the source of this article): his mutual

Full text and comments »

  • Vote: I like it
  • +1018
  • Vote: I do not like it

52.
By majk, 7 years ago, In English
Codeforces Global Round 4 <img src="/predownloaded/2e/e2/2ee2f0f95f05aae6ca6f47812dae2dc2aabf277b.png" style="width:200px; float:right; margin: 0 1em 1em 1em"/> Hi! On [contest_time:1178] we will host [contest:1178]. It is the fourth round of a new series of [Codeforces Global Rounds](https://codeforces.me/blog/entry/65002) supported by XTX Markets. The rounds are open for everybody, the rating will be updated for everybody. You will be given 8 problems and 150 minutes to solve them. The scoring distribution will be **500-750-1250-1750-2000-(1500+1500)+3250+4000**. The prizes for this round: - 30 best participants get a t-shirt. - 20 t-shirts are randomly distributed among those with ranks between 31 and 500, inclusive. The prizes for the 6-round series in 2019: - In each round top-100 participants get points according to the [table](https://pastebin.com/QT5sXEaT). - The final result for each participant is equal to the sum of points he gets in the four rounds he placed the highest. ...
/entry/65002) supported by XTX Markets. The rounds are open for everybody, the rating will be updated

Full text and comments »

Announcement of Codeforces Global Round 4
  • Vote: I like it
  • +875
  • Vote: I do not like it

53.
By sszcdjr, history, 2 years ago, In English
Refact.ai Match 1 (Codeforces Round 985, Div. 1 + Div. 2) Hello, Codeforces! We (KDOI Team) are glad to invite you to take part in [contest:2029], which is the 8th CP contest held by us! You can view the previous rounds by us [here](/blog/entry/135847). - Number of problems: $9$ ($0$ interactive); - Start time: [contest_time:2029]; - Contest duration: $180$ minutes; - Score distribution: $750-1250-1750-2250-2500-3000-3500-5000-5500$. The problems were authored and prepared by [user:Error_Yuan,2024-11-05], [user:wyrqwq,2024-11-05], [user:Otomachi_Una,2024-11-05] and me [user:sszcdjr,2024-11-05]. --- <img src="/predownloaded/73/e1/73e1593107761ee6b925164110aa7307488b2215.png" style="float:right; margin: 0 0 2em 2em; width:300px;"/> A few words from our sponsor: We’re [Refact.ai](https://refact.ai/?utm_source=codeforces&utm_medium=post&utm_campaign=round_09112024&utm_content=cf_short_09112024), an open-source AI Coding Assistant, and on November 9th, we’ll be hosting our first round on Codeforces! Winners will receive ...
=round_09112024&utm_content=cf_short_09112024), an open-source AI Coding Assistant, and on November 9th, we’ll

Full text and comments »

  • Vote: I like it
  • +655
  • Vote: I do not like it

54.
By MikeMirzayanov, 8 years ago, translation, In English
Hello, ITMO! <img src="https://assets.codeforces.com/images/itmo-logo.png" style="margin:1em 1em 1em 1em; float:right;"/> Hi Codeforces! For you, perhaps it was yet another Codeforces round. But not for me. [contest:1066] is the first round tested on new judging servers at ITMO University. And this is not just an update of location. Ta-dam! Now your solutions will be judged on the new Intel i3-8100 processors. And this is not all news. The number of judging servers has increased, which means fewer queues during rounds! I am pleased to announce that now I live in St. Petersburg, I work at ITMO, and Codeforces is gradually moving from the walls of dear to me Saratov University to ITMO University. The decision to move was not easy for me. My plan is that, based on ITMO, I can focus more on Codeforces development and work on the platform. The number of world champions per square meter is simply overwhelming, and working with a large team of such enthusiasts (and professionals!) of sports pro...

Full text and comments »

  • Vote: I like it
  • +1331
  • Vote: I do not like it

55.
By MikeMirzayanov, history, 11 years ago, translation, In English
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 &mdash; 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 ...
-hour period of open hacks — any visitor of Codeforces may try to hack any complete solution to a, ; * After the end of the round will be a 24-hour period of open hacks — any visitor of

Full text and comments »

  • Vote: I like it
  • +1052
  • Vote: I do not like it

56.
By antontrygubO_o, history, 7 years ago, In English
On problemsetting 2 [Previous part](https://codeforces.me/blog/entry/70178) Hi there again! Previous part with opinions of some amazing problemsetters turned out to be interesting for you, so I decided to gather some more opinions :D. I really hope that this post will help someone in their problemsetting future! #### When and how did you start problemsetting? [user:300iq,2020-01-11]: April, 2017 [user:maroonrk,2020-01-11]: In 2015 Summer, I hold the first contest with friends at high school club. It was a local Japanese contest. [user:Radewoosh,2020-01-11]: In high school, so probably for 5 years. I was creating problems for other people from my school as my teacher told me that it's a completely different point of view. [user:voidmax,2020-01-11]: It was 3 years ago. I was on plane and I didn't have a clue what to do in my free time. Then I realized that I can try myself in problemsetting. Later I created first and one of my favorite problem ([problem:963B]). I was full of inspiration a...
[Triangular Lamps Hard](https://atcoder.jp/contests/wtf19-open/tasks/wtf19_c2), [e](https://atcoder.jp/contests/wtf19-open/tasks/wtf19_e), [user:maroonrk,2020-01-11]: We should be open to constructive criticism, but they are too few.

Full text and comments »

  • Vote: I like it
  • +631
  • Vote: I do not like it

57.
By antontrygubO_o, 7 years ago, In English
Ozon Tech Challenge 2020 Hello Codeforces! <center> <img alt="ozon" src="https://codeforces.me/predownloaded/6a/99/6a99904b94e5c20a149198e2dde4068dadd9278a.png" style="float:right; height: 200px; margin: 10px; max-width:50%;"/> </center> We are glad to invite you to the upcoming “[Ozon Tech Challenge 2020](https://codeforces.me/contests/1305)”, which will start at [contest_time:1305]. The round will be open and rated for everybody! This round is initiated and supported by Ozon. Ozon — one of the leading players in e-commerce (provides its customers with over 2.5 million product names in 24 categories), a tech company that actively developing its IT department. They already have the largest Golang team in Russia, a proprietary WMS fulfillment management system completely written by the Ozon team, 250 million lines of logs per day, collected on the site and in the Ozon mobile application. Ozon experts perform at the leading profile conferences GoperCon, Heisenbug, GoWayFest, GolangConf, and also ...
/contests/1305)”, which will start at [contest_time:1305]. The round will be open and rated for everybody!

Full text and comments »

  • Vote: I like it
  • +754
  • Vote: I do not like it

58.
By artew, 3 years ago, translation, In English
Codeforces Round #932 (Div. 2) <img alt=" " src="https://i.imgur.com/EFlomVE.png" style="float: right;max-width: 100.0%;max-height: 100.0%;width:30%;height:30%"> <h2>Hello, Codeforces! &#128519;</h2> ------------------ We are glad to invite you to participate in [contest:1935], which will take place at [contest_time:1935] &#128293; &#128561; &#129321; The round has been fully prepared by students of the School CPM &#128147; (School of the Pedagogical Skills Center): [user:IzhtskiyTimofey,2024-02-25], [user:AndreyPavlov,2024-02-25], and myself. The theme of all the problems will be our beloved school &#128520; This round will be **rated** for participants with a rating below **2100** &#128522; Participants with a higher rating can take part out of competition &#128523; We would like to thank &#128149;: - Our wonderful coordinator [user:Artyom123,2024-02-25] for helping prepare the problems and valuable advice! &#128525; - CPM students [user:azureglow,2024-02-25] and [user:max0000561,2024-02-25] ...
participants of the upcoming Open Olympiad in Informatics and ROI! 🥇

Full text and comments »

  • Vote: I like it
  • +911
  • Vote: I do not like it

59.
By SlavicG, 5 years ago, In English
How to use Codeforces [GUIDE] I see a lot of newcomers struggling to use the website to it's fullest, so I decided to write a blog that has all important information about how to use Codeforces in a single place. I will update it with time, so feel free to write your suggestions/questions in case I missed something and I will be glad to add it to the post! I would like to thank [user:_Vanilla_,2022-02-05] and [user:mesanu,2022-02-05] for helping me write the blog, and [user:Monogon,2022-02-05], [user:down,2022-02-05] and [user:AlperenT,2022-02-05] for proofreading and giving suggestions. #### Navigating through pages ![ ](https://media.discordapp.net/attachments/705371983650619454/928235498487570442/bandicam_2022-01-05_12-36-00-134.jpg?width=991&height=110) It's possible to navigate through most pages of Codeforces using the bar on the top, I will talk about what each tab does more in depth below: #### The Help Page The help page contains the answer to a lot of questions about Codeforces, such as rati...
a 12 hour open hacking phase where all users can look at others submissions and try to find a, feature update and such. You are directly sent to the home page when you open Codeforces but it's also, this types of contest values the same amount. After the round, there is a 12 houropen hacking phase, - Open rounds — these rounds are open and rated for everyone. The format is the same as for, To view a solution click the Source (the long number in the first column of the table). To select

Full text and comments »

  • Vote: I like it
  • +726
  • Vote: I do not like it

60.
By feecIe6418, 4 years ago, In English
Codeforces Global Round 21 Hello Codeforces! On [contest_time:1696] we will hold [contest:1696]. **<img src="/predownloaded/2e/e2/2ee2f0f95f05aae6ca6f47812dae2dc2aabf277b.png" style="width: 200.0px;float: right;margin: 0 1.0em 1.0em 1.0em;max-width: 100.0%;max-height: 100.0%;">** It is the third round of a 2022 series of [Codeforces Global Rounds](https://codeforces.me/blog/entry/65002). The rounds are open and rated for everybody. The prizes for this round: - 30 best participants get a t-shirt. - 20 t-shirts are randomly distributed among those with ranks between 31 and 500, inclusive. The prizes for the 6-round series in 2022: - In each round top-100 participants get points according to the [table](https://pastebin.com/QT5sXEaT). - The final result for each participant is equal to the sum of points he gets in the four rounds he placed the highest. - The best 20 participants over all series get sweatshirts and place certificates. Thanks to XTX, which in 2022 supported the global ...
/entry/65002). The rounds are open and rated for everybody.

Full text and comments »

Announcement of Codeforces Global Round 21
  • Vote: I like it
  • +749
  • Vote: I do not like it

61.
By soullless, 10 months ago, translation, In English
Похоже, против LLM-читинга мы смотрим не на то ### 1. Что именно за проблема Во время раундов появилась конкретная схема: участник получает у LLM готовый код и просто отправляет его, почти не понимая. Это не всегда ловится плагиатом: человек может изменить переменные, поменять местами некоторые части кода. ### 2. Идея #### Xeppelin — open-source tool, изначально сделанный для ICPC, который: - запускается локально перед контестом - логирует изменения файлов в рабочей директории - сохраняет таймлайн разработки (когда и как менялся код) - не записывает экран, клавиатуру, сеть или вкладки - после контеста строит визуализацию активности #### [Это не мой tool, но вы можете найти его тут](https://github.com/KiK0S/xeppelin) ### 3. Что именно предлагается для Codeforces (реализация, не идея) Предложение — использовать Xeppelin как внешний источник поведенческих данных, без вмешательства в CF-инфраструктуру. Поток работы: 1. Участник запускает Xeppelin перед раундом 2. Решает задачи как обычно (локально, в ...
#### Xeppelin — an open-source tool, originally made for ICPC, which:, #### Xeppelin — open-source tool, изначально сделанный для ICPC, который:, The proposal is to use Xeppelin as an external source of behavioral data, without interfering with

Full text and comments »

  • Vote: I like it
  • +392
  • Vote: I do not like it

62.
By Dominater069, 2 years ago, In English
Analyzing how good O1-Mini actually is I would like to thank [user:redpanda,2024-09-13] and [user:qmk,2024-09-13] for their great help in writing and reviewing this blog. They are also the users who queried O1-mini for all the following problems. We tried O1-mini on several problems, from a variety of sources. Let's list the results first. **Note** : - Some of the WA verdicts here actually means that the AI just "stopped thinking" which means the AI thought for a long enough time without any useable results so it ran into an error. - All ratings mentioned are Codeforces ratings, the Atcoder ratings have been converted to codeforces rating. To measure the approximate codeforces rating of the atcoder problems mentioned here, you can use https://kenkoooo.com/atcoder/#/table/ + https://silverfoxxxy.github.io/rating-converter. <h4> D2ABs </h4> - [problem:1762B] [<a class="rated-user user-gray" title="Gray">1100</a>] <a class="rated-user user-green" title="Green AC">AC</a> - [problem:1998B] [<a class="rated-...

Full text and comments »

  • Vote: I like it
  • +583
  • Vote: I do not like it

63.
By bicsi, history, 6 years ago, In English
I might get stigmatized for this, but here it goes Recently, Moscow Fall Workshops has taken place (it ended about one week ago), and I wanted to address some issues that came into my mind during that period. As you might notice, it took me some time to build the courage and get in the right mindset to write about this. First of all, I want to say that I am a huge supporter of programming camps and, in general, initiatives to enhance the joy of doing competitive programming and I respect the efforts of building communities around CP. I have always had a kind of excitement when thinking about participating in programming camps (Petrozavodsk, Moscow Workshops, etc.) and their “hardcore” style with lots of contests. I therefore appreciate the immense efforts of organizers, problem setters, and testers, when preparing this camp. ### Main point Coming towards the main point of the blog, I felt that the last programming camp was a bit… underwhelming. Moreover, I’m having a hard time trying to justify the costs of doing such a camp,...
partly to try to understand the situation, and partly to open up to the community about this. My, open (and hoping) to change my mind about this.

Full text and comments »

  • Vote: I like it
  • +795
  • Vote: I do not like it

64.
By shiven, history, 23 months ago, In English
A summary of what passes for an Indian ICPC Contest, apparently The online round for the India’s ICPC was held on 23rd. And also a week before that. The first time around, the organisers tried debuting a self-hosted DOMjudge instance. That didn’t go too well, so a recontest was scheduled on CodeChef. If you’re not too familiar with the Indian ICPC system — this online prelims is used to select teams that can participate in the offline regionals. From a single university, usually approx. 2 teams (for the top unis) or 1 (for almost all unis that aren’t in top-15) qualify. As you could guess, it’s quite easy for good teams to miss a spot. Looking at the first contest’s rankings, teams from rank 2 to 100+ all had 4 solves. Owing to severe system issues in the first contest, the time penalties weren’t too reliable differentiators, leading to the recontest this Saturday. In hindsight, we forgot to be grateful for the problemset and reliable testcases the first time. I’m sure everyone agrees that the basic requirements (ignoring all other stuff...

Full text and comments »

  • Vote: I like it
  • +925
  • Vote: I do not like it

65.
By vovuh, history, 6 years ago, In English
My thoughts on clarifications and on the round #677. Alright, I'm done. I wanted to write a blog like that for a long time, but now I really don't have enough patience to ignore this issue anymore. I want to say that I get 100-200 clarifications each Div.3 round. It doesn't even matter how well the statements are, it doesn't matter if there are any issues with solutions or checkers, people always find what to ask. Before I start whining here, I really want to recommend anyone to read these two [user:Um_nik,2020-10-20] blogs: [this one](https://codeforces.me/blog/entry/62730) and [this one](https://codeforces.me/blog/entry/62744). Sorry, [user:Um_nik,2020-10-20], I unnecessarily tagged you, I will not do that anymore. Now some breaking news for most participants: _your local IDE compiler_ and _Codeforces compiler_ are **actually** different things! If your code works fine locally but gets WA/TL/RE/ML/etc on Codeforces, it (most probably) means you have a bug somewhere in your code. There are rare cases when the issue is with comp...
quality source of understanding **how to read and understand statements**. Please, read the statement

Full text and comments »

  • Vote: I like it
  • +979
  • Vote: I do not like it

66.
By RDDCCD, history, 4 years ago, In English
CodeTON Round 4 (Div. 1 + Div. 2, Rated, Prizes!) Hello, Codeforces! I'm very glad to invite you to participate in [CodeTON Round 4 (Div. 1 + Div. 2, Rated, Prizes!)](https://codeforces.me/contests/1810), which will start on [contest_time:1810].You will be given **8 problems** and **2 hours** to solve them. The round will be rated for everyone. I'd like to give my sincere thanks to: * [user:74TrAkToR,2023-03-29] for the wonderful coordination! * [user:Sulfox,2023-03-29] for the help with the statements. * [user:Suika_predator,2023-03-29], [user:SSerxhs,2023-03-29], [user:LLL_2820,2023-03-29], [user:xay5421,2023-03-29], [user:NemanjaSo2005,2023-03-29], [user:applese,2023-03-29], [user:bxhnb,2023-03-29], [user:fr200110217102,2023-03-29], [user:Sulfox,2023-03-29], [user:CCSU_DZX,2023-03-29] [user:PaperCloud,2023-03-29], [user:CedeaT0,2023-03-29], [user:Kath1031,2023-03-29], [user:jcccc,2023-03-29], [user:dyxg,2023-03-29], [user:tzc_wk,2023-03-29], [user:xiaoziya,2023-03-29], [user:qiqi20021026,2023-03-29], [user:Pointy,20...
_The Open Network (TON) is a fully decentralized layer-1 blockchain designed to onboard billions of

Full text and comments »

  • Vote: I like it
  • +687
  • Vote: I do not like it

67.
By maomao90, 3 years ago, In English
Editorial for Hello 2024 ### [problem:1919a] Author: [user:maomao90,2024-01-02] <spoiler summary="Hint 1"> When does the game end? </spoiler> <spoiler summary="Solution"> Depending on whether the player chooses to exchange wallets with their opponent on step $1$, $1$ coins will be removed from either the opponent's wallet or the player's wallet. This means that if either of the players still has remaining coins, the game will not end as at least one of the choices will still be valid. The only way that the game ends is when both players have $0$ coins. Since each operation decreases the total amount of coins by exactly $1$, the only way for Alice to win the game is if $a + b$ is odd. </spoiler> <spoiler summary="Code"> ~~~~~ #include <bits/stdc++.h> using namespace std; int main() { int t; cin >> t; while (t--) { int a, b; cin >> a >> b; if ((a + b) % 2 == 0) { cout << "Bob\n"; } else { cout << "Alice\n"; } } ...
Consider a flow graph with $n + 2$ vertices. Let the source vertex be

Full text and comments »

Tutorial of Hello 2024
  • Vote: I like it
  • +760
  • Vote: I do not like it

68.
By GlebsHP, history, 4 years ago, In English
Nebius Welcome Round (Div. 1 + Div. 2, rated, t-shirts!) Hello, Codeforces! [user:Zlobober,2023-03-09] and I are glad to invite you to compete in Nebius Welcome Round (Div. 1 + Div. 2) that will start on [contest_time:1804]. The round will be rated for everyone and will feature 8 problems that you will have 2 hours to solve. I feel really thrilled and excited about this round as this is the first time I put so much effort in a Codeforces contest since I quit being a round coordinator in December 2016 (wow, that was so long ago)! We conduct this round to have some fun and we also hope to find some great candidates to join Nebius team. Solving 5+ problems in our round will be a good result and will count as one of the coding interviews. Apart from that top 25 contestants and 25 random contestants placed 26-200 will receive a branded Nebius t-shirt! <img style="float: right; margin: 0 1em 0.5em 1em; width: 400px;" src="/predownloaded/40/37/403770e78d9c8962d0bc0c20a9e1c45d0e3c5df9.png"> Some information about Nebius. I have join...
Here you can check [Nebius website](https://nebius.com/) and [open positions](https

Full text and comments »

  • Vote: I like it
  • +720
  • Vote: I do not like it

69.
By ToxicPie9, 3 years ago, In English
You won't believe how this simple trick defeated the unexplained bug destroying every top LGM ### TL;DR Currently people are discussing a slowdown bug on Codeforces that seems to happen randomly, and can cause code to run 100x slower and get TLE. More details in [user:pajenegod,2024-03-03]'s [blog post](https://codeforces.me/blog/entry/126654). In this article, I present a mitigation: add the following to your code. ~~~~ #include <windows.h> void *operator new(size_t size) { if (void *ptr = HeapAlloc(GetProcessHeap(), 0, size ? size : 1)) return ptr; throw std::bad_alloc{}; } void operator delete(void *ptr) { HeapFree(GetProcessHeap(), 0, ptr); } ~~~~ <spoiler summary="If you use malloc/free in C++ (you shouldn't), also change them."> ~~~~ void *my_malloc(size_t size) { if (void *ptr = HeapAlloc(GetProcessHeap(), 0, size ? size : 1)) return ptr; throw std::bad_alloc{}; } void my_free(void *ptr) { HeapFree(GetProcessHeap(), 0, ptr); } ~~~~ </spoiler> <spoiler summary="If you use aligned new/delete in C++, also change the...
functions are provided by the operating system, could they be the source of bugs? We can test this by, libraries or STL, the lack of source code (and the sheer complexity) makes the Windows API [impossible to, setup Codeforces has, but we can first investigate what each library does. Fortunately, thesource, Then we look at MSVCRT's source code. It also uses Windows API functions, except when it doesn't

Full text and comments »

  • Vote: I like it
  • +794
  • Vote: I do not like it

70.
By EvenImage, history, 3 years ago, In English
2nd Universal Cup Announcement Hello everyone, we are happy to announce that the 2nd Universal Cup has started officially. The Universal Cup is a non-profit organization dedicated to offering training resources for competitive programming teams. Our website is [https://ucup.ac/](https://ucup.ac/) (in English and Chinese). In the previous season, over 750 teams from more than 300 affiliations all over the world, registered and participated in a total of 22 stages, encompassing contests from Asia, Europe, and America. With the permission of contest setters and without involving copyright disputes, the Universal Cup will hold mirror contests for some undisclosed competition sets. It is expected to hold at least 20 contests in this season. We will simulate the actual situation in the competition, executing the board freeze in the last hour. At the same time, we will provide an overall rating board, which will help the team to make a reasonable assessment of itself. Over the past few weeks, the committee has...
The first contest will be the stage Qingdao on September 2nd, 2023. The contest source is The 2018

Full text and comments »

  • Vote: I like it
  • +654
  • Vote: I do not like it

71.
By cold_chair, history, 18 months ago, In English
An Open-Source Retrieval Model and Service for Competitive Programming Problems Over the past few years, the number of *duplicate* or *nearly-duplicate* problems in competitive programming has grown noticeably. You can find several discussions about this on Codeforces, for example: * [https://codeforces.me/blog/entry/113064](https://codeforces.me/blog/entry/113064) * [https://codeforces.me/blog/entry/113251](https://codeforces.me/blog/entry/113251) * [https://codeforces.me/blog/entry/118883](https://codeforces.me/blog/entry/118883) To address the issue, we collected a variety of data — problem–solution pairs, duplicate-problem pairs, and pairs of full vs. simplified problem statements. With these data we built a dedicated **benchmark for problem retrieval** and trained a **special-purpose retrieval model** that currently achieves the best performance among open-source models in this domain. You can try the model-powered search service live at **[https://cpret.online/](https://cpret.online/)**. About two years ago, the project [yuantiji.ac](http...
An Open-Source Retrieval Model and Service for Competitive Programming Problems, achieves the best performance among open-source models in this domain., among open-source models in this domain. You can try the model-powered search service live at, -retrieve* pipeline based on a closed-source LLM API. In contrast, **our approach is pure retrieval, More importantly, **the entire model is open-source**. If you’d like to run the search service, Questions or issues? Open an issue on GitHub — we’d love to hear your feedback!

Full text and comments »

  • Vote: I like it
  • +268
  • Vote: I do not like it

72.
By purplesyringa, 5 years ago, In English
This is not an exit. ![This is not an exit.](https://i.ibb.co/N9zrDNp/cf.png) I am looking at the post called [*Is Mike Mirzayanov dictator?*](https://codeforces.me/blog/entry/94033) at the moment. I'm reading through the comments, I'm looking at people's reactions, I'm reading Mike's replies, and... I am utterly disappointed. I demand progress. For context, I do believe Codeforces is the best website for competitive programming contests at the moment. I sincerely give credit to Mike for creating Codeforces and providing participants and contest authors a platform for interaction completely for free. I am confident that Codeforces is the most appropriate website for being *the* platform for sharing knowledge, exchanging tricks and methods, and collaboration between both contest participants, their authors, and coordinators. **Please consider this an open letter**, for this is a will not of a single person, but of many individuals. Please consider signing it by stating so in a comment under the...
**Please consider this an open letter**, for this is a will not of a single person, but of many, . We could theoretically take Mike's word for it. But hey, [IOI isolate is open- source for a reason, Codeforces is, after all, possibly the largest submission dataset. What about releasingopen data, The happy ending we cannot hope for is for Codeforces to be released under an open-source, though, You open the site, you click through the links, and when something catches your attention and you

Full text and comments »

  • Vote: I like it
  • +527
  • Vote: I do not like it

73.
By adamant, history, 2 years ago, In English
CP-Algorithms: Hacktoberfest 2024 + call for contributors and maintainers Hi everyone! <img src="/predownloaded/82/15/821540e8f87d8a2b2d468377aacbba80b0aa1623.png" style="float:right;" width=100px> I'm posting this on behalf of **[CP-Algorithms](https://cp-algorithms.com/)**, a community project that [started off](https://codeforces.me/blog/entry/13198) in 2014 by [user:RodionGork,2024-10-13] as a translation of [e-maxx](http://e-maxx.ru/), a Russian go-to resource at the time by [user:e-maxx,2024-10-13] for learning core competitive programming algorithms. Since then, CP-Algorithms grew quite a lot (which also prompted a rename from original project name `e-maxx-eng`) and includes a lot of new, original articles, and a lot of translated articles were enhanced and/or extended or even completely rewritten, amounting to a total of 157 articles at the moment. At the moment, the project is largely maintained by [user:Jakube,2024-10-13] and [user:adamant,2024-10-13] (that's me), but as it happens, we don't have as much time to dedicate to it as we used...
open source and get a t-shirt for it. Not sure what to help us with? Consider the following:

Full text and comments »

  • Vote: I like it
  • +347
  • Vote: I do not like it

74.
By nyavim, history, 2 years ago, In English
Another Graph Editor! **UPDATE (5 Dec 2024)** There have been a few new features since its initial release. - Multiple graphs/testcases (each "tab" can store its own testcase so you can visualize all testcases at once) - Multi-edge support - Bipartite mode - More appearance-related configuration sliders Thanks for all the support and suggestions! Things will continue to be added slowly over time, but if there's a particular feature that you want you can just open an issue on GitHub. --- Hello, Codeforces! I've been working on a graph visualization tool for a while now, and because I couldn't think of a good name for it, I've opted to call it *Another Graph Editor*. If you have any name suggestions, pls let me know. Here's the [website](https://anacc22.github.io/another_graph_editor/) and the [repo](https://github.com/anAcc22/another_graph_editor). ![ ](https://github.com/anAcc22/another_graph_editor/blob/main/screenshots/main.png?raw=true) The layout is very much inspired by CS A...
if there's a particular feature that you want you can just open an issue on GitHub.

Full text and comments »

  • Vote: I like it
  • +811
  • Vote: I do not like it

75.
By Um_nik, history, 2 years ago, In English
Hacking (as a CF feature) does not fit modern competitive programming 1. How does hacking work with the new feature of unrated registration? I have seen this question raised in the comments to the announcement several times, but there is no answer still and I think it's weird that Mike hasn't thought about it before announcing. 2. I was working recently on a div.2 Codeforces round (still might happen in the future) and I was told by my coordinator that pretests should be equal to systests in all the problems. From this I can conclude that it is a Codeforces policy and intentionally weak pretests do not happen. It doesn't mean that it is impossible to hack anybody, but it doesn't sound like a viable strategy. I find it weird that this information is not public, it's like I'm getting bonus information about all other Codeforces rounds by setting a round myself. I have done exactly zero research on the matter, but my feeling is that 99% of hacks (I'm talking about during-the-round-hacking here, not open hacking of education rounds and such) happen in ...
about during-the-round-hacking here, not open hacking of education rounds and such) happen in rare, talking about during-the-round-hacking here, not open hacking of education rounds and such) happen in

Full text and comments »

  • Vote: I like it
  • +1015
  • Vote: I do not like it

76.
By KAN, 9 months ago, translation, In English
Codeforces Blitz Cup 2026 <center style="margin: 2em;"> <img src="/predownloaded/a7/e8/a7e8478b9af90246ebd2a4e42b9bbbafd392b64f.png"/> </center> Hi Codeforces! I have a great announcement for you. This month, we're holding the second Codeforces Blitz Cup! Remember all the WA1s and CEs we've seen from LGMs stressing out to submit before the opponent? They are coming back! The Codeforces Blitz Cup is a single-elimination personal tournament where matches follow the special Blitz Rules. In short, each match is a 40-minute PvP contest, where problems open one by one, and only the first AC counts. The players can't use any help or prewritten code except a small template, and we get to watch them think and code live. - [Detailed rules](/r/blitz-rules) - [Bracket](/publish/blitz2026/bracket.html) Check out last year's final rounds streams: [day 1](https://www.youtube.com/watch?v=caoeMuNNQtg&embeds_referring_euri=https%3A%2F%2Fcodeforces.com%2F), and the [final day 2](https://www.youtube.com/watch?v=...
special Blitz Rules. In short, each match is a 40-minute PvP contest, where problemsopen one by one, and

Full text and comments »

  • Vote: I like it
  • +684
  • Vote: I do not like it

77.
By Kuroni, history, 3 years ago, In English
Codeforces Global Round 25 Xin chào Codeforces (・ω・)ノ We are pleased to announce the resumption of the Global Rounds. Thanks to XTX Markets for supporting the initiative! In 2024, we will hold 4 such rounds. The series results will take into account the best 3 participations out of 4. On [contest_time:1951] we will host [contest:1951]. **<img src="/predownloaded/2e/e2/2ee2f0f95f05aae6ca6f47812dae2dc2aabf277b.png" style="width: 200.0px;float: right;margin: 0 1.0em 1.0em 1.0em;max-width: 100.0%;max-height: 100.0%;">** Codeforces Global Round 25 marks the first round in the 2024 series of Codeforces Global Rounds. These rounds are open and rated for everyone. The prizes for this round are as follows: - The top 30 participants will receive a t-shirt. - 20 t-shirts will be randomly distributed among participants ranked between 31 and 500, inclusive. The prizes for the 4-round series in 2024: - In each round, the top-100 participants get points according to the [table](https://pastebin.com...
. These rounds are open and rated for everyone.

Full text and comments »

Announcement of Codeforces Global Round 25
  • Vote: I like it
  • +605
  • Vote: I do not like it

78.
By SecondThread, history, 5 years ago, In English
CF Sweatshirt signed by legends at ICPC World Finals Good morning! ICPC World Finals just concluded in Moscow. I was lucky enough to be participate representing the University of Central Florida, who finished in a respectable 17th place. While there, friends, acquaintances, and CF Legends signed my Codeforces sweatshirt in their handle with their current color. The most common request of the people I asked was to show off what it ended up looking like on a blog post of Codeforces, so here that is! ![ ](https://wumbogames.github.io/cfPictures/IMG_2102.png) ![ ](https://wumbogames.github.io/cfPictures/IMG_2101.png) <spoiler summary="Famous Signings"> ![ ](https://wumbogames.github.io/cfPictures/IMG_2075.png) ![ ](https://wumbogames.github.io/cfPictures/IMG_2078.png) </spoiler> #### Signers: - [user:MikeMirzayanov,2021-10-11] the creator and maintainer of Codeforces and Polygon who deserves our eternal thanks, and [user:Una_Shem,2021-10-11] without whose work there would be no sweatshirt to sign. - [user:tourist,2021-1...
to share, the comments below are always open.

Full text and comments »

  • Vote: I like it
  • +772
  • Vote: I do not like it

79.
By MikeMirzayanov, 8 years ago, translation, In English
Codeforces: Results of 2018 Hi Codeforces! February 2019 is already on the calendar, which means that I was late with the report for 2018. Better late than never! Let's remember last year. In 2018, [user:_kun_,2019-02-05], [user:300iq,2019-02-05] and [user:arsijo,2019-02-05] joined the team of coordinators. The work of the coordinators is headed (and is the coordinator of the coordinators) [user:KAN,2019-02-05]. I really hope that a more measured schedule of preparing rounds by a large team of coordinators will give a better insight into the contests. The main innovations in the platform are implemented by me and the developers [user:kuviman,2019-02-05], [user:fcspartakm,2019-02-05], [user:MaximShipko,2019-02-05]. Great work on the organization of events and prizes mailing was done by [user:gKseni,2019-02-05]. Special thanks to the writers of the problems and testers. It is your content that charges the community with life and unites all of us. Thank you for the problems! And now let's summarize...
* **Mail.Ru**, Mail.Ru Cup — open individual programming competition, consists of several, problem edit page 1. Show checker source code in a review mode 1. Add problems from one contest to

Full text and comments »

  • Vote: I like it
  • +871
  • Vote: I do not like it

80.
By TheScrasse, 3 years ago, In English
Pinely Round 3 (Div. 1 + Div. 2) <img src="https://assets.codeforces.com/images/pinely_logo.png" align="right" style="height: 200px;" alt="text"/> Ciao, Codeforces! We're glad to invite you to take part in [contest:1909], which will start on [contest_time:1909]. You will be given **9 problems** and **3 hours** to solve them. One of the problems will be divided into two subtasks. The problems were authored and prepared by me. <spoiler summary="Spoiler"> ![ ](https://i.imgur.com/lipiKQE.png) </spoiler> We would like to thank - [user:errorgorn,2023-12-20] for his fun &#129292; &#x1F921; &#x1F913; &#x1F629; coordination; - [user:Alexdat2000,2023-12-20] for Russian translation; - [user:franv,2023-12-20] for writing $173$ lines of checker of problem H correctly at the first try; - [user:franv,2023-12-20] for pictures in the editorial; - [user:dario2994,2023-12-20], [user:Endagorion,2023-12-20], [user:ffao,2023-12-20], [user:Golovanov399,2023-12-20], [user:nor,2023-12-20] for VIP testing; - [user:Kaey,202...
-latency trading. They have offices in Amsterdam, Limassol, Singapore, and Shanghai and areopen for job

Full text and comments »

  • Vote: I like it
  • +797
  • Vote: I do not like it

81.
By Um_nik, history, 14 months ago, In English
On AI ruining "solving math problems with computer" [a year later] I guess you were right in the part "a year from now LLMs will solve problems on your level". You were also saying something along the lines of "you'll change your mind when it starts affecting you". In this part, you were wrong. Cheaters always existed, and they always will. LLMs make it easier to cheat, true. There is no way of completely preventing LLM cheating (or any other kind of cheating) in online competitions. I just coordinated the round everyone is buzzing about, so I can with confidence say that in the CF rules for coordinators and authors, there isn't anything about making problems LLM-proof. Not for easy problems, not for hard problems, nothing. And I doubt any such rules will appear. LLMs are forbidden by the rules, that's that. So we, as honest participants (yes, I will assume that you are an honest participant, otherwise this blog is not applicable to you and I don't care about you), will have to accept that some problems in the future rounds will be LLM-able, ...
everyone solves G in 5 minutes, but then you open it and it is a scary number theory in which you need 10, " in G. I was always saying that you shouldn't open standings during the contest, if you can get a, open standings during the contest, if you can get a solve count for every problem. Heck, in a CF round

Full text and comments »

  • Vote: I like it
  • +680
  • Vote: I do not like it

82.
By BledDest, history, 3 years ago, translation, In English
Educational Codeforces Round 152 [Rated for Div. 2] Hello Codeforces! On [contest_time:1849] [contest:1849] 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.me/blog/entry/51208">blog post</a>. This round will be **rated for the participants with rating lower than 2100**. It will be held on extended ICPC rules. The penalty for each incorrect submission until the submission with a full solution is 10 minutes. After the end of the contest, you will have 12 hours to hack any solution you want. You will have access to copy any solution and test it locally. You will be given **6 or 7 problems** and **2 hours to solve them**. The problems were invented and prepared by Adilbek [user:adedalic,2023-07-26] Dalabaev, Mikhail [user:awoo,2023-07-26] Piklyaev, Maksim [user:Neon,2023-07-26] Mescheryakov and ...
processes_ - _Experience with open-source projects is highly preferred_

Full text and comments »

  • Vote: I like it
  • +322
  • Vote: I do not like it

83.
By SecondThread, 2 years ago, In English
Meta Hacker Cup 2024 Schedule — Introducing the Meta Hacker Cup AI Track Meta Hacker Cup 2024 ================== Meta Hacker Cup is back! We’re excited to announce our schedule for our 2024 season, kicking off on September 20th! - Practice Round: [Fri. September 20th, 10am Pacific (72 hours)](https://www.timeanddate.com/worldclock/fixedtime.html?msg=Meta+Hacker+Cup+Practice+Round&iso=20240920T10&p1=234)* - Round 1: [Sat. October 5th, 10am Pacific](https://www.timeanddate.com/worldclock/fixedtime.html?msg=Meta+Hacker+Cup+Round+1&iso=20241005T10&p1=234&ah=3) (3 hours) - Round 2: [Sat. October 19th, 10am Pacific](https://www.timeanddate.com/worldclock/fixedtime.html?msg=Meta+Hacker+Cup+Round+2&iso=20241019T10&p1=234&ah=3) (3 hours) - Round 3: [Sat. November 2nd, 10am Pacific](https://www.timeanddate.com/worldclock/fixedtime.html?msg=Meta+Hacker+Cup+Round+3&iso=20241102T10&p1=234&ah=3) (3 hours) - Finals: [Sat. December 7th, 6am Pacific](https://www.timeanddate.com/worldclock/fixedtime.html?msg=Meta+Hacker+Cup+Finals&iso=20241207T10&p1=234&ah=4) (4 hou...
/hacker-cup). Registration will open July 24th.

Full text and comments »

  • Vote: I like it
  • +528
  • Vote: I do not like it

84.
By chenjb, history, 5 years ago, In English
XXII Open Cup: GP of EDG Hello! I'm happy to announce XXII Open Cup: Grand Prix of EDG, which will be held on Nov 14th, 2021. This contest is mainly prepared by Zhejiang University, which has already been used as the 2021 CCPC Guilin Contest. On the same day of the 2021 CCPC Guilin Contest, Team [Edward Gaming (EDG)](https://en.wikipedia.org/wiki/Edward_Gaming) from [League of Legends Pro League (LPL, China)](https://en.wikipedia.org/wiki/League_of_Legends_Pro_League) won the Champion of [the 2021 League of Legends World Championship](https://en.wikipedia.org/wiki/2021_League_of_Legends_World_Championship) held in Reykjavík. They are also the only LPL team entering the semi-finals while the rest of three teams all coming from [League of Legends Champions Korea (LCK, Korea)](https://en.wikipedia.org/wiki/League_of_Legends_Champions_Korea), including the champion from last year. Almost nobody would bet on their winning, but they made it and reclaim the glory for LPL after 2 years. ![ ](https://news.cgtn...
XXII Open Cup: GP of EDG, Hello! I'm happy to announce XXII Open Cup: Grand Prix of EDG, which will be held on Nov 14th, 2021

Full text and comments »

  • Vote: I like it
  • +350
  • Vote: I do not like it

85.
By Sharon, history, 8 years ago, In English
I am removing my contest proposal from Codeforces I am removing my contest proposal from Codeforces. Note: This is a serious blog post. Also, the opinions presented in this blog are my own and not of my friend [user:BiIIy,2018-12-26] who wrote the contest with me. Today I have removed my contest proposal from Codeforces. I should probably have done this a long time ago. The proposal was made in February, but the problems were written and finished by March, and that is when I opened the contest proposal for review and messaged [user:KAN,2018-12-26]. It is currently December and no progress or development has been made regarding my contest proposal since, so I will be removing it. I have multiple reasons for removing my contest proposal: - I have no motivation to host an online contest anymore. - I am involved in problem setting with two other high school programming contests in my university, and I write, host, and judge another contest for local high schools. - I have forgotten that I “was in the queue” for writing a...
Div3, if Codeforces wishes to allow people to write problems for these in the future). Once youopen

Full text and comments »

  • Vote: I like it
  • +830
  • Vote: I do not like it

86.
By MikeMirzayanov, 4 years ago, In English
Looking For EDU Lecturers <img src="/predownloaded/47/86/4786c2ec901c0b5b490794ca6fd5145f0dcdeae3.png" style="float:right; width: 400px; margin: 0 1em 1em 1em"/> Hello! I always like to think that Codeforces is not only a place where you come to compete but also a place where you can learn. Learn new things. Two years ago, we launched the [EDU](https://codeforces.me/edu/courses) subproject, a platform for publishing classes. There are already several classes, but there are so many interesting topics around! The Codeforces team can write the platform, make the technical foundation, but it would be great to write content with the support of the community. Thanks to the support of competitive programming alumni, we have a budget for targeted grants for the preparation of new classes in the EDU section. Hope we have new content soon! We are looking for lesson authors who could prepare and record one or more lessons. Those who are now red or have ever been red are invited. We assume that one le...
form (open until June 28th).

Full text and comments »

  • Vote: I like it
  • +772
  • Vote: I do not like it

87.
By kuviman, 9 years ago, translation, In English
Codeforces: acm.sgu.ru comes back <img src="/predownloaded/e6/11/e6110c2bbfaa42c460f7c54f681a89fa9fe2395a.png" alt="acmsguru" title="acmsguru" style="float:right; margin: 0 1em 1em 1em;"/> Hello everyone! [acm.sgu.ru](http://acm.sgu.ru/) was created ~16 years ago by programming contests participants from Saratov university: [user:MikeMirzayanov,2018-04-23] and [user:andrewlazarev,2018-04-23]. Today its codebase and infrastructure are completely outdated, and supporting it is unreasonably hard. Nonetheless, Codeforces team is regularly asked to revive acmsguru, since there is still a lot of interest in the problemset. Here is the new functionality in Codeforces &mdash; additional section ["acmsguru" in Problemset](/problemsets/acmsguru). All the problems from the old system are moved there. There are still a few things to do here: correctly port interactive problems, improve looks of statements, support the new section in [Codeforces API](/api/help), support adding these problems to mashups. Anyway, you can ...

Full text and comments »

  • Vote: I like it
  • +734
  • Vote: I do not like it

88.
By -is-this-fft-, history, 4 years ago, In English
On "is this greedy or DP", forcing and rubber bands #### Introduction When it comes to "problem-solving techniques", there are roughly 3 levels: 1. Concrete algorithms (Kruskal's algorithm, Li-Chao tree, fast Fourier transform) 2. General patterns (dynamic programming, greedy, square-root decomposition) 3. Meta-strategies ("how do I even go about solving this problem?") There is some grey area, but in general this classification works well. [Many tutorials](https://codeforces.me/catalog) have been written about ideas that fall into 1 or 2. But very little has been written about the third category. On the catalog, I think the only blogs that really qualify are [this](62730) and [this](20548). There is also [this](92248?#comment-809401) valuable comment. As to why there is so little written, I think I can identify two reasons. - Most strong contestants don't really consciously think about these. After solving a problem with FFT, it's hard not to know you used FFT. If you used DP, even if you did it without thinki...
problems and learned pretty quickly that it doesn't work. This is in fact the source of the name

Full text and comments »

  • Vote: I like it
  • +548
  • Vote: I do not like it

89.
By simonlindholm, history, 9 years ago, In English
Open sourcing KTH's Team Reference Document We just made KTH's ICPC team reference document [open source](https://github.com/kth-competitive-programming/kactl). It contains a few nice things that I haven't seen elsewhere: - Ergonomic API's for [SCC](https://github.com/kth-competitive-programming/kactl/blob/master/content/graph/SCC.h), [biconnected components](https://github.com/kth-competitive-programming/kactl/blob/master/content/graph/BiconnectedComponents.h), [2-SAT](https://github.com/kth-competitive-programming/kactl/blob/master/content/graph/2sat.h), [angle sweepings](https://github.com/kth-competitive-programming/kactl/blob/master/content/geometry/Angle.h), and [monotone function partitioning](https://github.com/kth-competitive-programming/kactl/blob/master/content/various/ConstantIntervals.h). - I don't recall seeing [tridiagonal linear equation solving](https://github.com/kth-competitive-programming/kactl/blob/master/content/numerical/Tridiagonal.h) or [tree compression](https://github.com/kth-competitive-programmi...
Open sourcing KTH's Team Reference Document, We just made KTH's ICPC team reference document [open source ](https://github.com/kth-competitive

Full text and comments »

  • Vote: I like it
  • +127
  • Vote: I do not like it

90.
By tourist, 3 months ago, In English
Cognition @ IOI 2026 Cognition is sponsoring the IOI this year! [user:ecnerwala,2026-08-08], [user:tourist,2026-08-08], [user:skittles1412,2026-08-08], and [user:walnutwaldo20,2026-08-08] will all be there. We'll have a booth in the Fun Zone after both contest days, and we'll generally be hanging around throughout the week. Come by and say hi, we'd love to meet you! Competitive programming runs deep at Cognition. Many of our engineers competed in high school olympiads, and our founders ([user:scott_wu,2026-08-08], [user:stevenkplus,2026-08-08], and [user:walnutwaldo20,2026-08-08]) are all IOI gold medalists. One fun fact: every IOI from 2006 through 2025 had at least one Cognition employee competing in it. Today, Cognition is one of the largest AI startups in the world. We're building the future of software engineering and working with Fortune 500 companies to transform how they build software. We hope to see you in Tashkent. Until then, here's a fun warmup problem :) <spoiler summary="Problem"...
(source: https://dmoj.ca/problem/ciw26p2)

Full text and comments »

  • Vote: I like it
  • +521
  • Vote: I do not like it

91.
By dj3500, 12 years ago, In English
Hightail — automatic tester for programming contests Hi! In this post I would like to introduce you to an application called [Hightail](http://github.com/dj3500/hightail). [Hightail](http://github.com/dj3500/hightail) is an automatic tester for programming contests such as CodeForces rounds. It will parse the problem statement, extract sample test cases (inputs and outputs) from it, and verify the correctness of your program against them. It is built to provide maximum automation and to relieve the contestant as much as possible. A list of Hightail's features: - parsing problem statements - parsing entire contests (autoloading all problems) - scheduling contest parsing ahead of time - ability to comfortably view, edit and add test cases - handling of all verdicts: WA, TLE, RE, even AC - customizable time limits - ability to create in/out files in your working directory - detection of floating point values (comparing 0.1 vs. 0.10 does not give WA) - easy-to-use UI, keyboard shortcuts - resilient: it is multi-threaded so ...
became a small open source project when some other people contributed code to it. I think that it is now

Full text and comments »

  • Vote: I like it
  • +508
  • Vote: I do not like it

92.
By brunomont, 5 months ago, In English
Chinese Postman Problem: How I Ran a 180 km Ultramarathon Through Every Street in My City Hello, Codeforces! A couple of years ago, a friend of mine told me that two cyclists had passed through every single street in the center region of the city I live in (Belo Horizonte, southeastern Brazil), on the [third try](https://www.strava.com/activities/1030665876/overview). <spoiler summary="First try"> After ~160 km, they had not completed 1/3 of the goal. [Strava link](https://www.strava.com/activities/976021527). <img src="/predownloaded/8a/53/8a53829f7d78e88808a3ff751b64406ec2fc0efd.png" style="width: 600.0px;max-width: 100.0%;max-height: 100.0%;"> </spoiler> <spoiler summary="Second try"> They were better prepared, but one of the guys was run over by a car (no big injuries). [Strava link](https://www.strava.com/activities/999450285). <img src="/predownloaded/85/8f/858fdcdcfda93cd1d9c7c59db7dbfad9e63d6ea2.png" style="width: 600.0px;max-width: 100.0%;max-height: 100.0%;"> </spoiler> <center> <img src="/predownloaded/8d/5c/8d5cfb677a361654105e49f36f214c35...
same street; 4. Streets that "close" (its access is not always open for the public, for instance

Full text and comments »

  • Vote: I like it
  • +802
  • Vote: I do not like it

93.
By Radewoosh, history, 5 years ago, In English
My own algorithm — offline incremental strongly connected components in O(m*log(m)) Hello Codeforces! As all of you know, there are so many known algorithms named after people who invented them &mdash; from the easiest ones, like Dijkstra, to the harder ones, like Berlekamp–Massey algorithm. These algorithms were innovative when they were invented, so of course, it's good that they are named after their inventors. But, today, I've seen a blog about the solution to the problem "compute LCS of two strings in time $O((n + k) \cdot \log(k))$, where $n$ is the sum of lengths of the strings, and $k$ is the number of pairs of matching positions in them". To be honest, it a bit pissed me off that even this algorithm is named after its creators. Is it ok to name the solution to every possible problem after its author? I won't judge it. Anyway, I want my very own Radecki algorithm, so let me give it a try. If anyone has ever heard about it &mdash; it's cool. Let me know, and it'll be just another helpful blog on Codeforces. Let's imagine the following problem: there is...

Full text and comments »

  • Vote: I like it
  • +543
  • Vote: I do not like it

94.
By tourist, 4 years ago, In English
Codeforces Round #844 Editorial [problem:1782A] <spoiler summary="Explanation"> [tutorial:1782A] </spoiler> <spoiler summary="Source"> ~~~~~ #include <bits/stdc++.h> using namespace std; int main() { int tt; cin >> tt; while (tt--) { int w, d, h; cin >> w >> d >> h; int a, b; cin >> a >> b; int f, g; cin >> f >> g; int ans = b + abs(a - f) + g; ans = min(ans, a + abs(b - g) + f); ans = min(ans, (d - b) + abs(a - f) + (d - g)); ans = min(ans, (w - a) + abs(b - g) + (w - f)); cout << ans + h << '\n'; } return 0; } ~~~~~ </spoiler> [problem:1782B] <spoiler summary="Explanation"> [tutorial:1782B] </spoiler> <spoiler summary="Source 1"> ~~~~~ #include <bits/stdc++.h> using namespace std; int main() { int tt; cin >> tt; while (tt--) { int n; cin >> n; vector<int> cnt(n + 1); for (int i = 0; i < n; i++) { int a; cin >> a; cnt[a] += 1; } int ans = 0; ...
~~~~~ #include

Full text and comments »

  • Vote: I like it
  • +253
  • Vote: I do not like it

95.
By shishyando, 5 years ago, In English
Codeforces Global Round 16 **Hello, Codeforces!** On [contest_time:1566] we will host [contest:1566]. **<img src="/predownloaded/2e/e2/2ee2f0f95f05aae6ca6f47812dae2dc2aabf277b.png" style="width: 200.0px;float: right;margin: 0 1.0em 1.0em 1.0em;max-width: 100.0%;max-height: 100.0%;">** It is the fourth round of a 2021 series of [Codeforces Global Rounds](https://codeforces.me/blog/entry/65002). The rounds are open and rated for everybody. The prizes for this round: - 30 best participants get a t-shirt. - 20 t-shirts are randomly distributed among those with ranks between 31 and 500, inclusive. The prizes for the 6-round series in 2021: - In each round top-100 participants get points according to the [table](https://pastebin.com/QT5sXEaT). - The final result for each participant is equal to the sum of points he gets in the four rounds he placed the highest. - The best 20 participants over all series get sweatshirts and place certificates. Thanks to XTX, which in 2021 supported the gl...
/entry/65002). The rounds are open and rated for everybody.

Full text and comments »

Announcement of Codeforces Global Round 16
  • Vote: I like it
  • +692
  • Vote: I do not like it

96.
By Qingyu, 5 years ago, In English
An archive of old USACO Problems As we know, USACO is a competitive programming contest primarily for secondary school students in the US. It offers a large collection of excellent problems, from the easy to the difficult. Many of the problems are educational and worthwhile as training material. However, the official website only offers problems from as early as 2011, and older problems are hard to find. Some of the Online Judges, such as POJ, contain some of the problems, but they are not properly filed together, and it's difficult to find the corresponding solution and test data. In this post, I will try to list all the USACO materials that I have found so far. Most of the materials come from some old websites, and thanks to the efforts of web.archive.org, we can check out old websites that no longer exist. In addition, many of the problems were used as training materials in the training of Chinese IOI teams about 20 years ago. These materials have been preserved and are available through some Chinese websit...
+ Testdata + Analysis](http://usaco.org/index.php?page=feb22results) | | USACO 2022Open | Bronze, websites. It is important to note that since some of the materials are from a singlesource, I cannot, | | [Statement](https://qoj.ac/files/Release1/1999n.txt) | | USACO 1999 Spring Open | Silver | | | USACO, | | | | USACO 1998 Spring Open | | [Statement](https://qoj.ac/files/Release1/1998spring.txt) | | USACO, It is important to note that since some of the materials are from a single source, I cannot confirm, Open | Bronze | [Statement + Testdata + Analysis](http://usaco.org/index.php?page=open15results, Open | Bronze | [Statement + Testdata + Analysis](http://usaco.org/index.php?page=open16results, Open | Bronze | [Statement + Testdata + Analysis](http://usaco.org/index.php?page=open17results, Open | Bronze | [Statement + Testdata + Analysis](http://usaco.org/index.php?page=open18results, Open | Bronze | [Statement + Testdata + Analysis](http://usaco.org/index.php?page=open19results, Open | Bronze | [Statement + Testdata + Analysis](http://usaco.org/index.php?page=open20results, Open | Bronze | [Statement + Testdata + Analysis](http://usaco.org/index.php?page=open21results, | Contest | Division | Archive | | :-: |:-: | :-: | | USACO 2000 Spring Open | Orange, | Contest | Division | Archive | | :-: |:-: | :-: | | USACO 2001 US Open | Orange | [Testdata, | Contest | Division | Archive | | :-: |:-: | :-: | | USACO 2002 US Open | Orange | [Statement

Full text and comments »

  • Vote: I like it
  • +323
  • Vote: I do not like it

97.
By -is-this-fft-, history, 5 years ago, In English
[Tutorial] The command line: how to read input from file without #ifdef and much more #### Introduction Instead of algorithms and math, I'll be doing something completely different here. There is something that has bothered me for a long time: people not understanding the tools they use to participate in contests and thus failing to take real advantage of them. And it all goes back to not understanding the command line. Some of you might say, "well surely, the command line is something obsolete and you're only clinging to it because you [insert ridiculous amateur-psychology here]?" No! The command line is not obsolete, and unless competitive programming becomes so mainstream that software vendors start writing professional-grade tools aimed specifically at us, it won't be. [cut] $~$ What is the command line? Any of these: ![ ](/predownloaded/bd/b6/bdb6c157b9b3ce5ae046c9064e469e0081f8c0fe.png) As you can see, it comes in many background colors and fonts, but the basic idea is always the same. It's a box you can type commands in, which it will ...
- On Windows, open the Start menu and search for "cmd.exe". - On Mac, open the Finder and search, Once you have got it open, type `ls` (Linux/Mac) or `dir` (Windows) and press Enter. You should

Full text and comments »

  • Vote: I like it
  • +443
  • Vote: I do not like it

98.
By defnotmee, 2 years ago, In English
Catching the Mole II(Hard Version) (Psychotic_D cheating case aftermath) This is a part 2 of [my other blog](https://codeforces.me/blog/entry/131821) on the [user:Psychotic_D,2024-07-23] situation. I highly recommend you see it before this one for context. If you don't care that much, here is a quick recap of what was covered in the other blog before we get started: [user:Psychotic_D,2024-07-23] had a ridiculously good performance on his friend's ([user:wuhudsm,2024-07-23]) round. This let many people become suspicious of whether he achieved this legitimately. Then multiple accusations were thrown around and I did my blog doing my own investigation and compiling the most compelling evidence I found. The takeaway was that [user:Psychotic_D,2024-07-23] was probably cheating along [user:EndlessDreams,2024-07-23], who would give him code for [user:Psychotic_D,2024-07-23] to copy. [user:Psychotic_D,2024-07-23] would alter them heavily to avoid plagiarism, but it was clear beyond a reasonable doubt that he was cheating. Well, I finished writing that blog, ...
the source of that code. [user:chromate00,2024-07-23] has later apologized and reformed since that, I mean, he is the first thing that appears when you open the TheForces group, he must be pretty

Full text and comments »

  • Vote: I like it
  • +586
  • Vote: I do not like it

99.
By Qingyu, history, 18 months ago, In English
The 3rd Universal Cup. Stage 38: Guangzhou (CCPC Finals 2024) Hi everyone! We are thrilled to invite you to The 3rd Universal Cup, Stage 38: Guangzhou, taking place on May 24th, 2025. The contest is based on the Finals of the CCPC (China Collegiate Programming Contest), which was held on May 11th, 2025. This is my third time to be a judge on the CCPC Finals, and probably my last experience of my judging experience in high school. This contest is prepared by [user:Gellyfish,2025-05-22], [user:johnvictor,2025-05-22], [user:jqdai0815,2025-05-22], [user:Kevin114514,2025-05-22], [user:Kubic,2025-05-22], [user:lynkcat,2025-05-22], [user:Milmon,2025-05-22], [user:ODT,2025-05-22], [user:orzdevinwang,2025-05-22], [user:Qingyu,2025-05-22], [user:rddccd]. Although the style of problems differs a lot, the difficulty of this problem set is close to the ICPC World Finals or Regional Semifinals (NERC Finals or Asia EC Finals). We believe the problems will be engaging for participants of all levels while still providing a challenge for the strongest te...
Finals 2022) + [XXI Open Cup named after E.V. Pankratiev, Grand Prix of Beijing](https://qoj.ac/contest

Full text and comments »

  • Vote: I like it
  • +499
  • Vote: I do not like it

100.
By flamestorm, 4 years ago, In English
April Fools Day Contest 2023 Hello, Codeforces! I, along with [user:AlperenT,2023-03-30], [user:Ari,2023-03-30], [user:BucketPotato,2023-03-30], [user:ScarletS,2023-03-30], and [user:ToxicPie9,2023-03-30], would like to invite everyone on Codeforces to the [contest:1812]! The 11th April Fools Day Contest will take place on [contest_time:1812]. This is a joke competition in which solving the problem is often easier than figuring out what the actual task is. Please note that the round is **unrated**. In this round you'll be given $n$ weird problems and 2 hours to solve them, where $7 \leq n \leq 12$. At most $\sqrt{n}$ of the problems will be [interactive](https://codeforces.me/blog/entry/45307). The contest will use ACM ICPC rules (no hacks, the standings are decided by the number of solved problems and penalty time earned on them). You can submit solutions in any language allowed by Codeforces, unless the problem says otherwise. To get an idea of what the contest will look like, you can check out the ...
**UPD4**: Sorry for the inconvenience, the contest is now open for practice submissions + virtuals.

Full text and comments »

  • Vote: I like it
  • +576
  • Vote: I do not like it

101.
By E869120, 7 years ago, In English
My winning theory in IOI 2018 & 2019 — Why I won 2 golds in IOI Dear Codeforces community.<br /> According to [IOI 2019 Results](http://stats.ioinformatics.org/results/2019), I got the 25th place and got successful gold medals twice in a row.<br /> Although it was pretty close to the gold-medal border (only 6.14pts / 600 difference) and it was lower performance than IOI 2018, which I participated when I was orange in Codeforces, I had many chances to get more points in this IOI, even for top 10. Since there are not so many people who have got two gold medals in IOI (and there were many requests like "I want [user:E869120,2019-08-14] to talk about how to get gold in IOI" like [this comment](https://codeforces.me/blog/entry/66909?#comment-510127) and [this comment](https://codeforces.me/blog/entry/66909?#comment-513129)). I want to write something about IOI, which may be useful for people who will participate in IOI next year and also some years later.<br /> ![ ](https://i.ibb.co/TLmqRRX/E869120-IOI-01.png)<br /> <br /> ### A. First of all At...
Olympiad in Informatics (JOI)](https://oj.uz/problems/source/45), [Central European Olympiad in Informatics, ://ioi2019.az/source/Tasks/Day2/Vision/vision.pdf) has 8 subtasks! For a problem which has many subtasks, ](https://oj.uz/problem/view/IOI15_boxes), [IOI 2019 Shoes](https://ioi2019.az/ source/Tasks/Day1, source code of output only bugged, while time is running out. In the contest duration 5:13:50 — I

Full text and comments »

  • Vote: I like it
  • +608
  • Vote: I do not like it

102.
By Noam527, 6 years ago, In English
[Tutorial] Supporting Queue-like Undoing on DS In many data structures, the operation of "undo" on the last update can be implemented easily: we can (usually) maintain a stack of the updates, where each update on the stack holds the memory cells it changed, and their original values. To undo an operation, just revert all changes from the top update on the stack. To maintain good complexity, we require the updates to operate in non-amortized time. I've seen this being used multiple times on DSU (without path compression). If we imagine the updates as a sequence, then we can push an update to the end, and pop an update from the end by undo. Then, this sequence is a stack of updates. Here we discuss the idea of having a queue of updates: we can add a new update, or undo the oldest update still active. Specifically, this blogpost attempts to solve the following problem: Given a data structure that can support some updates, some queries and an "undo" operation (each with their own time complexity), how can we create a data structu...
Open Questions ------------------ Although we showed some kind of optimality in a general case

Full text and comments »

  • Vote: I like it
  • +474
  • Vote: I do not like it

103.
By SecondThread, history, 6 years ago, In English
Petition to revoke unrated account permissions to post comments/blogs Unrated Account Disaster ================== Recently there have been an obscene number of unrated accounts showing up. Several of them have inappropriate names, so I won't give examples because I want to keep this post clean, but I'm sure you have seen them in the comments. They are likely all by the same individual, possibly with a few copy-cat troublemakers as well. Recently, certain ones have begun to spam useless comments on old posts to clog up the recent actions, effectively hiding all relevant conversations except on the blog posts they spam on. For whatever reason, these are overwhelmingly on [user:Errichto,2020-07-10]'s old blog posts. Occasionally there are also a flood of obscene blog posts made by the user themselves. Here's an example of what I mean: ![ ](https://wumbogames.github.io/cfPictures/Spam.png) #### This is obnoxious and I would like to see it stop. The current solution clearly doesn't work. As soon as they get banned or muted or whatever, they c...
source, we can 'trust' these users with the GM 'trust this user' feature. As far as I know, there aren't

Full text and comments »

  • Vote: I like it
  • +761
  • Vote: I do not like it

104.
By TLE, history, 3 years ago, In English
Finally, semantic search for competitive programming problems Hello Codeforces, It has been a long while, but in [this project](https://github.com/fjzzq2002/is-my-problem-new) we close the long-standing open problem proposed by [Umnik 2021](https://codeforces.me/blog/entry/95956). You can try it here _(discontinued, see the new link below)_ while supplies last. Currently I only imported problems from Codeforces & BZOJ (the dead Chinese OJ) but adding other OJs should be easy as long as we have the statements crawled (PRs?). Cheers! **Update (8 months later):** We finally got an update! In the new version I collected and uploaded most of vjudge (which means 160k problems!). It also got a shiny new domain [http://yuantiji.ac](http://yuantiji.ac). Enjoy! :D
close the long-standing open problem proposed by [Umnik 2021](https://codeforces.me/blog/entry, /is-my-problem-new) we close the long-standing open problem proposed by [Umnik 2021](https

Full text and comments »

  • Vote: I like it
  • +1200
  • Vote: I do not like it

105.
By PurpleCrayon, history, 5 years ago, In English
Codeforces Global Round 18 <img src="/predownloaded/2e/e2/2ee2f0f95f05aae6ca6f47812dae2dc2aabf277b.png" style="width:200px; float:right; margin: 0 1em 1em 1em"/> Happy Holidays! On [contest_time:1615] we will host [contest:1615]. It is the sixth round of a 2021 series of [Codeforces Global Rounds](/blog/entry/65002). The rounds are open and rated for everybody. The presents for this round: - 30 best participants get a t-shirt. - 20 t-shirts are randomly distributed among those with ranks between 31 and 500, inclusive. The presents for the 6-round series in 2021: - In each round top-100 participants get points according to the table. - The final result for each participant is equal to the sum of points he gets in the four rounds he placed the highest. - The best 20 participants over all series get sweatshirts and place certificates. Thanks to XTX, which in 2021 supported the global rounds initiative! The problems were written and prepared by the hard-working elves [user:1-gon,2021-12...
are open and rated for everybody.

Full text and comments »

Announcement of Codeforces Global Round 18
  • Vote: I like it
  • +609
  • Vote: I do not like it

106.
By errorgorn, 5 years ago, In English
Linear Basis (Xor Basis Extended) As part of the graduation requirements for my school, I have to complete a simple research project, so I decided to do something related to data structure and algorithms. I believe I have come out with a data structure that maintains the basis of vectors in $(\mathbb{Z}/m\mathbb{Z})^d$, where $m$ **may not be prime**. Since this was related to competitive programming, I think it is a good idea to share it here. Hopefully, this algorithm is actually novel :P I would like to thank: - [user:icypiggy,2021-12-26] for being my research mentor and tolerating my dumb questions - [user:rama_pang,2021-12-26] and [user:adamant,2021-12-28] for their helpful suggestions and comments Please comment under the blog or message me on codeforces if any parts are unclear or wrong. Also, I hope that some LGMs can help solve the open problems in this blog. # Introduction Maintaining the basis of vectors in $(\mathbb{Z}/2 \mathbb{Z})^d$, also known as the xor basis algorithm is a well-studie...
# Open Problems, , I hope that some LGMs can help solve the open problems in this blog.

Full text and comments »

  • Vote: I like it
  • +381
  • Vote: I do not like it

107.
By pajenegod, history, 6 years ago, In English
(Request) Update PyPy's Version on CF I've always liked using Python (PyPy) for solving problems in competitive programming. And most problems are very doable, even in Python. What I've found is that the most difficult problems to solve in Python are those requiring 64 bit integers. The reason why 64 bit integers are problematic is because CF runs Windows, and PyPy only supports 32 bit on Windows. So whenever a problem involves integers that cannot fit inside of a signed 32 bit int, PyPy switches to big integers (which runs insanely slow, sometimes a factor of 20 times slower). <spoiler summary="What I currently have to do to get around big integers"> ### 1. Switching to floats What I usually try is switching from using integers to floats. This works if all integers are $\leq 2^{52}$: [submission:53441394] (Fat TLE and almost MLE) vs [submission:53456822] (AC by a mile) ### 2. Calculating `a * b % MOD` Many problems on CF involve doing multiplication modulo $10^9 + 7$. This is super slow because of big integ...

Full text and comments »

  • Vote: I like it
  • +642
  • Vote: I do not like it

108.
By Monogon, history, 5 years ago, In English
[Tutorial] Blossom Algorithm for General Matching in O(n^3) I have decided to write a tutorial on a topic not even [user:Um_nik,2021-06-29] knows! ([source](https://codeforces.me/blog/entry/92248)) In this tutorial, I will talk about the blossom algorithm, which solves the problem of **general matching**. In this problem, you are given an undirected graph and you need to select a subset of edges (called matched edges) so that no two edges share a vertex, and the number of matched edges is maximized. More common in competitive programming is bipartite matching, which is the same problem but when the graph is guaranteed to be bipartite. In competitive programming, general matching seems to get a lot of hate for being very challenging to implement. However, the blossom algorithm is quite beautiful, and important in the history of algorithm research. It will help if you are already familiar with bipartite matching. I will discuss the high level ideas of the algorithm, but my main focus will be on the tricky implementation details. So you may...
I have decided to write a tutorial on a topic not even [user:Um_nik,2021-06-29] knows! ([source

Full text and comments »

  • Vote: I like it
  • +384
  • Vote: I do not like it

109.
By cry, 3 years ago, In English
CodeTON Round 8 (Div. 1 + Div. 2, Rated, Prizes!) Hello Codeforcers! ================== We are pleased to invite you to participate in [contest:1942]. This round will start on [contest_time:1942] and will be **rated for all participants**. There will be $8$ problems to be solved in $3$ hours, with one divided into two subtasks. Similar to [USACO](https://usaco.org/), you will help Farmer John and his cows resolve a series of first world problems. Be there or be square. This round was cooked up by [user:smax,2024-03-10], [user:sum,2024-03-10], [user:oursaco,2024-03-10], [user:cry,2024-03-13], and [user:buffering,2024-03-10]. We would like to thank the following people for making the round possible: - Our favorite cherry [user:TheScrasse,2024-03-10] for the wonderful and speedy coordination. - Our MVP testers, [user:Benq,2024-03-10], [user:Geothermal,2024-03-26], and [user:rainboy,2024-03-26], for dedicating so much time to reviewing problems, providing essential feedback, and perfecting the problemset. - The rest of ...
_The Open Network (TON) is a fully decentralized layer-1 blockchain designed to onboard billions of

Full text and comments »

  • Vote: I like it
  • +505
  • Vote: I do not like it

110.
By cry, 14 months ago, In English
Codeforces Round 1050 (Div. 4) <center> <img src="https://codeforces.me/predownloaded/aa/9f/aa9f258454379845a0619839fde95151d3902e8f.png" style="width:100px;"/> </center> <div class="youtube-container" style="float:right; margin:0 1em 1em 1em; text-align:center;"> <iframe width="315" height="560" src="https://www.youtube.com/embed/VK969nPLEcc" title="YouTube video player" frameborder="0" allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture; web-share" allowfullscreen></iframe> </div> I am extremely delighted to invite you to participate in my first solo round, [contest:2148], starting on [contest_time:2148]. There will be $7$ problems to be solved in $2$ hours and $15$ minutes. The format of the event will be identical to Div. 3 rounds: - ICPC rules with a penalty of 10 minutes for an incorrect submission; - 12-hour phase of open hacks after the end of the round (hacks do not give additional points) - after the end of the open hacking phase, all so...
- ICPC rules with a penalty of 10 minutes for an incorrect submission; - 12-hour phase ofopen

Full text and comments »

  • Vote: I like it
  • +551
  • Vote: I do not like it

111.
By vbandurin, history, 3 years ago, In English
Polygon Updates (August — September 2023) Hello, Codeforces! I, [user:ChurakovaAlexandra,2023-10-13], and [user:medvezhonokok,2023-10-13] are students of ITMO, and since this August, we started our internship at Codeforces. We are delighted that now we have the opportunity not only to write academic code but to do something that competitive programming enthusiasts from all over the world use. Currently, we are working on minor improvements to Polygon &mdash; a system for preparing problems. Later, as we gain more experience and delve into the technologies, we will also start working on Codeforces. A big thank you to our mentors [user:geranazavr555,2023-10-13] and [user:MikeMirzayanov,2023-10-13], who are always there to help and support. Here's a list of the main improvements to Polygon that we've made (sometimes with significant help from our mentors) over these two months. [cut]<br/> ###### 1. Automatic translation of solutions from one programming language to another. On the 'Solutions' page, a 'Tra...
changes and/or open bug issues., Added the ability to change the language for all source files in bulk. This can be done in the

Full text and comments »

  • Vote: I like it
  • +731
  • Vote: I do not like it

112.
By MikeMirzayanov, history, 11 years ago, translation, In English
Open Codeforces Rating System [updated on October 2015] Starting from October 2015 ratings formulas are open. They are given in the post. It is likely that from time to time we will change them slightly, it will be reflected here. The basic idea of Codeforces rating system is to generalize Elo rating to support games with multiple participants. Each community member is characterized by value $r_i$ &mdash; integer number. Roughly speaking, the higher value means better results in the contests. Rating is calculated/recalculated so that the equality strives to be correct: $$P_{i,j}=\frac{1}{1+10^{\frac{r_j-r_i}{400}}},$$ where $P_{i,j}$ is probability that the $i$-th participant has better result than the $j$-th participant. Therefore for two participants the probability to win/lose depends on subtraction of their ratings. For example, if the difference of ratings is equal to 200 then stronger participant will win with probability ~0.75. If the difference of ratings is equal to 400 then stronger participant will win with probabi...
Open Codeforces Rating System [updated on October 2015], Starting from October 2015 ratings formulas are open. They are given in the post. It is likely that

Full text and comments »

  • Vote: I like it
  • +395
  • Vote: I do not like it

113.
By errorgorn, 5 years ago, In English
Invitation to TOKI Regular Open Contest #24 Hello again Codeforces &#x1f44b;, We are excited to invite you to **TOKI Regular Open Contest #24**! Key details: - Contest link: [TLX](https://tlx.toki.id/contests/troc-24) - Time: [18th December 2021, 13:05 UTC](https://www.timeanddate.com/worldclock/fixedtime.html?msg=TOKI+Regular+Open+Contest+%2324&iso=20211218T1305&p1=1440&ah=2&am=30) - Writers: [user:errorgorn,2021-12-13], [user:maomao90,2021-12-13], [user:oolimry,2021-12-13] - Duration: 150 minutes - Problems: 7, but one of the problems will have a subtask - Scoring distribution: **100 &mdash; 200 &mdash; 400 &mdash; 600 &mdash; (600 + 200) &mdash; 900 &mdash; 1000** Many thanks to: - [user:prabowo,2021-12-13] &#x1f468;&zwj;&#x2764;&#xfe0f;&zwj;&#x1f48b;&zwj;&#x1f468; for &#x1f552; coordinating the &#x1f466;&#x1f337; contest and translating our &#x1f4b0;&#x1f171; stupid &#x1f615;&#x1f4a9; jokes into &#x27a1; Indonesian &#x1f1ee;&#x1f1e9;. - [user:icypiggy,2021-12-13] for helping &#x1f4bb; us &#x1f1...
Invitation to TOKI Regular Open Contest #24, UTC](https://www.timeanddate.com/worldclock/fixedtime.html?msg=TOKI+Regular+ Open+Contest+%2324&iso, We are excited to invite you to **TOKI Regular Open Contest #24**!

Full text and comments »

  • Vote: I like it
  • +227
  • Vote: I do not like it

114.
By AmShZ, 6 weeks ago, In English
Contests for Math: Repovive Math Contest Grand Opening Hello everyone! Have you ever wished that math and combinatorics problems had the same live contest experience as competitive programming? We have, so we are building exactly that on Repovive! After beta testing our new Math section, we are ready to host the **Repovive Math Contest Grand Opening**. You can already try our beta math problems here: https://repovive.com/problems/math The theme of our first contest will be **Combinatorics**. The round will contain **5 combinatorics problems** to be solved in **2 hours and 30 minutes**. The problem set is intended to be suitable for a wide range of levels, so everyone is welcome to participate. The contest is **rated for everyone**. Since this is the first large live test of this format, we would especially love to have you participate, try the judging system, and share your feedback afterward. * Start Time: [Tuesday, 29 September 2026, 14:35 (UTC)](https://www.timeanddate.com/worldclock/fixedtime.html?iso=20260929T1...

Full text and comments »

  • Vote: I like it
  • +209
  • Vote: I do not like it

115.
By deltixlab, 5 years ago, In English
Codeforces Deltix Round Summer 2021 [Div.1 + Div.2] <a href="https://deltix.io/"><img alt="deltix" src="https://assets.codeforces.com/images/deltix/EcCsUtwbu1yq6Av.gif" style="float:right; height: 400px"/></a> <p>Привет, <span style="font-weight:bold">Code</span><span style="color:rgb(71,94,152);font-weight:bold">forces</span>!</p> Вас приветствует компания **[DELTIX](https://deltix.io/)**. Мы были основаны в 2005 году и являемся одним из лидеров в разработке программного обеспечения для исследований в финансовом домене и продуктов, решающих различные задачи системной и алгоритмической торговли. В 2020 году DELTIX присоединился к EPAM. Основной нашей задачей является быстрая и эффективная реализация перспективных идей в прорывные продукты. Мы являемся экспертами по следующим направлениям: - сбор, хранение, обработка данных - моделирование данных - тестирование и внедрение математических моделей Поэтому в нашей команде ценятся такие навыки, как - работа с алгоритмами - написание высокоэффективного кода - обработка ...
/finos/TimeBase-CE) joined a [FinTech Open-Source Foundation (FINOS)](https://www.finos.org/) on the, ://github.com/finos/TimeBase-CE) является частью open source сообщества [FINOS](https://www.finos.org/)., [TimeBase](https://timebase.info/) is a multi-faceted, open-source data-streaming powerhouse

Full text and comments »

  • Vote: I like it
  • +595
  • Vote: I do not like it

116.
By PurpleCrayon, 5 years ago, In English
[Tutorial] Simulated Annealing in Competitive Programming Hi Codeforces! I've recently noticed a lack of simulated annealing tutorials, so I decided to make one. It all started when I was trying to "cheese" [problem:1556H] after the contest. In general, simulated annealing is a pretty niche topic, but it can sometimes lend you unintended solutions for very hard problems. It's also very useful in contests like Google Hashcode, where you can add simulated annealing to an already good solution to make it a lot better. Simulated annealing's name and terms are derived from physical annealing, the process of letting metals or glass cool down and harden while removing internal stresses. An Overview ------------------ Simulated Annealing is an approximation algorithm. It's generally useful in problems with low constraints (i.e. $n \leq 50$ or $n \leq 100$) where you need to find the minimum/maximum of something over all possible states (and there are usually way too many of them to check). In general, it's good at finding the global maximum...
be added/changed, I'm always open to suggestions. If you have any other example problems, let me

Full text and comments »

  • Vote: I like it
  • +602
  • Vote: I do not like it

117.
By Amir_Parsa, 3 years ago, In English
Harbour.Space Scholarship Contest 2023-2024 (Div. 1 + Div. 2) Salam, Codeforces! $\color{white}{\text{ «Be attentive about your thought that becomes your behavior» «Be attentive about your behavior that becomes your speech» «Be attentive about your speech because it becomes your habit»«Be attentive about your habit because it becomes your personality»«Be attentive about your personality because it becomes your destiny» Said by: Imam Ali}}$ We're so excited to invite you to take part in our round [contest:1864] which will start on [contest_time:1864]. The round will be **rated and open for everyone**. The problems were prepared and authored by [user:amenotiomoi,2023-08-19], Dhruvil [user:Psychotic_D,2023-08-19] Kakadiya, Han [user:wuhudsm,2023-08-19] Jinlong, Amir Hossein [user:Amir_Parsa,2023-08-19] Farhadi, Matthew [user:Chromate00,2023-08-19] Roh, [user:JohnVictor,2023-08-19], [user:odt,2023-08-19], [user:ugly2333,2023-08-19], [user:lavine,2023-08-19], [user:RiverHamster,2023-08-19], [user:flowerletter,2023-08-19] and [user:Aquamoon...
[contest_time:1864]. The round will be **rated and open for everyone**.

Full text and comments »

  • Vote: I like it
  • +614
  • Vote: I do not like it

118.
By errorgorn, 4 years ago, In English
Invitation to TLX Regular Open Contest #30 <p> Selamat pagi Codeforces!</b> <img src="/predownloaded/2d/30/2d30c17aba8882b75b0b9b0aa7c222a519bcc7ba.png" style="width: 400.0px;float: right;margin: 0 1.0em 1.0em 1.0em;max-width: 100.0%;max-height: 100.0%;"> </p> We are excited to invite you to <b>TLX Regular Open Contest #30! Key details: - Contest URL: [TLX](https://tlx.toki.id/contests/troc-30) - Time: [7th January 2023, 14:05 UTC](https://www.timeanddate.com/worldclock/fixedtime.html?msg=TLX%20Regular%20Open%20Contest%20%2330&iso=20230107T140500) - Writer: minum susu ([user:errorgorn,2023-01-03], [user:Pyqe,2023-01-03], [user:rama_pang,2023-01-03], [user:nyab,2023-01-03]) - Duration: 150 minutes - Problems: 8 - Scoring distribution: **100 — 250 — 250 — 300 — 550 — 550 — 800 — 800** Many thanks to: - [user:Pyqe,2023-01-03], [user:steven.novaryo,2023-01-03] for coordinating the contest and translating the statements. - [user:dorijanlendvaj,2023-01-03], [user:gansus,2023-01-03], [user:nandonathaniel,202...
Invitation to TLX Regular Open Contest #30, We are excited to invite you to TLX Regular Open Contest #30!

Full text and comments »

  • Vote: I like it
  • +200
  • Vote: I do not like it

119.
By thecodingwizard, history, 6 years ago, In English
USACO Guide: Curated Resources for Competitive Programming & USACO **11/7/2020 Update**: Now open sourced at https://github.com/cpinitiative/usaco-guide [![USACO Guide Banner](/predownloaded/cd/f4/cdf40be60dc184cc6d1cb18e13d508a2853f75eb.jpg)](https://usaco.guide/) Link: https://usaco.guide/ Recently, a group of experienced USACO contestants (led by the legendary [user:Benq,2020-07-21]) have put together a "USACO Guide" that's designed to take you from any division to Platinum and beyond. It can be accessed here: https://usaco.guide/. Though it's structured around USACO, it can still be used by non-USACO contestants! The guide provides a curated list of tutorial resources you can use to learn a particular topic, as well as a lot of practice problems for you to practice your implementation & application skills. It also comes with progress-tracking tools to help you stay motivated :) This guide is still in the **pre-release** stage: a large number of modules, particularly the more advanced ones, are still incomplete. **We are looking for ...
**11/7/2020 Update**: Now open sourced at https://github.com/cpinitiative/usaco-guide

Full text and comments »

  • Vote: I like it
  • +562
  • Vote: I do not like it

120.
By Little09, 23 months ago, In English
Codeforces Global Round 28 Hello, Codeforces! We are pleased to announce the resumption of the Global Rounds. Thanks to XTX Markets for supporting the initiative! In 2024, we will hold 4 such rounds. The series results will take into account the best 3 participations out of 4. On [contest_time:2048] we will host [contest:2048]. **<img src="/predownloaded/2e/e2/2ee2f0f95f05aae6ca6f47812dae2dc2aabf277b.png" style="width: 200.0px;float: right;margin: 0 1.0em 1.0em 1.0em;max-width: 100.0%;max-height: 100.0%;">** Codeforces Global Round 28 marks the fourth round in the 2024 series of Codeforces Global Rounds. These rounds are open and rated for everyone. The prizes for this round are as follows: - The top 30 participants will receive a t-shirt. - 20 t-shirts will be randomly distributed among participants ranked between 31 and 500, inclusive. The prizes for the 4-round series in 2024: - In each round, the top-100 participants get points according to the [table](https://pastebin.com/NMzrRci8)....
. These rounds are open and rated for everyone.

Full text and comments »

Announcement of Codeforces Global Round 28
  • Vote: I like it
  • +563
  • Vote: I do not like it

121.
By PrinceOfPersia, 12 years ago, In English
Algorithm Gym :: Everything About Segment Trees In the last lecture of **Algorithm Gym** ([Data Structures](/blog/entry/15729)), I introduced you Segment trees. In this lecture, I want to tell you more about its usages and we will solve some serious problems together. [cut] Segment tree types : Classic Segment Tree -------------------- Classic, is the way I call it. This type of segment tree, is the most simple and common type. In this kind of segment trees, for each node, we should keep some simple elements, like integers or boolians or etc. This kind of problems don't have update queries on intervals. Example 1 (Online): Problem [problem:380C] : For each node (for example $x$), we keep three integers : 1.`t[x]` = Answer for it's interval. 2. `o[x]` = The number of $($s after deleting the brackets who belong to the correct bracket sequence in this interval whit length `t[x]`. 3. `c[x]` = The number of $)$s after deleting the brackets who belong to the correct bracket sequence in this interval whi...
Example : Problem [problem:76A], you can read my source code ([submission:8613428]) with this type, Source code of update function :

Full text and comments »

  • Vote: I like it
  • +323
  • Vote: I do not like it

122.
By Aris, 5 years ago, In English
Codeforces Round #764 (Div. 3) Hello! [contest:1624] will start at [contest_time:1624]. You will be offered 7-8 problems 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 a rating of 1600 or higher, can register for the round unofficially. The round will be hosted by rules of educational rounds (extended ICPC). Thus, solutions will be judged on preliminary tests during the round, and after the round, it will be a 12-hour phase of **open hacks**. You will be given **7-8 problems** and **2 hours and 15 minutes** to solve them. One of the problems in this round is **interactive**. Don't forget to read the [guide on interactive problems](https://codeforces.me/blog/entry/45307). Note that the **penalty** for the wrong submission in this round is **10 minutes**. [Remember](https://codeforces.me/blog/entry/59228) that only the trusted participants of the third division will be included in the official s...
**open hacks**.

Full text and comments »

  • Vote: I like it
  • +704
  • Vote: I do not like it

123.
By ko_osaga, history, 7 years ago, In English
Story about edge coloring of graph You are given a graph $G$, and for each vertex $v$ you have to assign a positive integer **color** such that every adjacent pair of vertices (vertices directly connected by edge) have different color assigned. You have to minimize the maximum color assigned: In other words, you have to minimize the number of distinct assigned colors. But that's [graph coloring](https://en.wikipedia.org/wiki/Graph_coloring) (vertex coloring). It's hard. Ok, one more time: You are given a graph $G$, and for each **edge** $e$ you have to assign a positive integer **color** such that every adjacent pair of edges (edges sharing same endpoints) have different color assigned. You have to minimize the maximum color assigned: In other words, you have to minimize the number of distinct assigned colors. This is the edge coloring of graph, and I will talk about this now. *Note that this can be interpreted as "graph coloring (vertex coloring) of line graphs". In that sense, you can consider in a similar...
bipartite matching with flows. We construct a usual flow graph with source and sinks, and find an, random walk from source, which means we will sample any outgoing edges with random probability, and

Full text and comments »

  • Vote: I like it
  • +361
  • Vote: I do not like it

124.
By prabowo, history, 6 years ago, In English
Asia-Pacific Informatics Olympiad 2021 Open Contest Dear Codeforces community, The **[Asia-Pacific Informatics Olympiad (APIO) 2021](https://apio2021.id/)** is going to take place this month. <img src="/predownloaded/d6/44/d644de3ae41b008fffe91cf178534a8d54b446ba.png" style="width:250px"/> We invite everyone to participate in the [APIO 2021 Open Contest](https://open.apio2021.toki.id/). The open contest will have the same problemset as APIO 2021 and will be held using CMS. The open contest will be held between [Monday, 24 May 2021 (05:00 UTC+0)](https://www.timeanddate.com/worldclock/fixedtime.html?iso=20210524T05&p1=1440) and [Wednesday, 26 May 2021 (05:00 UTC+0)](https://www.timeanddate.com/worldclock/fixedtime.html?iso=20210526T05&p1=1440). The duration of the contest is 5 hours, and you can participate at any time within that window. More details are available on [https://apio2021.id/open.html](https://apio2021.id/open.html). You can register and access the contest on [https://open.apio2021.toki.id/](https://open.apio...
Asia-Pacific Informatics Olympiad 2021 Open Contest, result for the open contest can be found [here](https://apio2021.id/open -results). - You can upsolve, **UPD**: The main competition has just ended, and the open contest has just started! We encourage, **UPD**: The open contest has ended! You may now discuss about the competition tasks. Feel free to, =VrJtt207bQc) today, and do not forget to register for the open contest!, Good luck with the open contest!, Open Contest](https://open.apio2021.toki.id/). The open contest will have the same problemset as, We invite everyone to participate in the [APIO 2021 Open Contest](https://open.apio2021.toki.id, We wish everyone to enjoy the open contest!

Full text and comments »

  • Vote: I like it
  • +314
  • Vote: I do not like it

125.
By Tony2_CF, history, 11 months ago, In English
The Time Complexity Lower Bound for Segment Tree Beats is log^2 Original Post: https://jiry-2.blog.uoj.ac/blog/1404 The following content is translated by Gemini 2.5 Pro. ## Part 1: Introduction to the Hacking Method ### How to Map the Hack Sequence to a Segment Tree First, we are given a Hack sequence of length $len$. After $O(1)$ range addition operations and $\Theta(\log len)$ global $\text{chkmax}$ operations, this sequence becomes a cyclic shift (rotation) of the original sequence. Since a cyclic shift does not affect our range addition and global $\text{chkmax}$ operations (we can simply shift the indices for the range addition accordingly), we can consider the sequence as unchanged. If we have such a sequence, let $len=n^{\frac{1}{3}}$, and place such a sequence at intervals of $n^{\frac{2}{3}}$. Each sequence corresponds exactly to a segment tree interval. A subtree of size $n^{\frac{2}{3}}$ contains exactly one such segment tree interval. For the Hack sequence, the range addition operations are performed one by one on eac...

Full text and comments »

  • Vote: I like it
  • +767
  • Vote: I do not like it

126.
By Kostroma, 7 years ago, In English
AIM Tech Poorly Prepared Contest (unrated, funny, div. 1 preferred) Hello! Traditionally AIM Tech organizes a big party for Petrozavodsk camp participants to have fun and get an opportunity to communicate with each other. Usually it comes along with **a funny contest in unusual format**. This year we decided to share the fun with all codeforces community! This year we came up with a format requiring (probably) less time for preparing the contest. It is somewhat similar to an ordinary contest with a 3-hour duration. We already have some problem ideas, so it should be super easy to prepare the problems just one night before the competition. We hope everything will run smoothly! The contest will start on [contest_time:1302]. It could be a bit rescheduled due to onsite delays. It will be **an unrated funny competition**. Unlike usual ICPC-style contests, you'll be given an archive with several open test cases and answers for each problem. You'll have some sample test cases in the statement too, they'll be included in the archive. However, the ...
archive with several open test cases and answers for each problem. You'll have some sample test cases, **UPD** It's still more than 4 hours before the contest, but the open tests are already prepared

Full text and comments »

  • Vote: I like it
  • +424
  • Vote: I do not like it

127.
By Qingyu, 15 months ago, In English
The 3rd Universal Cup Semifinals Hello everyone, we are happy to announce The 3rd Universal Cup Semifinals! The Semifinals will be held online to determine the teams advancing to The 3rd Universal Cup Finals. The contest takes place on August 24, 2025, at 11:00 UTC ([time in your local timezone](https://www.timeanddate.com/worldclock/fixedtime.html?iso=20250824T1900&p1=33&ah=5)) and will last 5 hours in the classical ICPC format. The contest is open to everyone. If you haven’t registered yet, join us today! <center style="margin: 2.5em;"> <a href="https://contest.ucup.ac/register" style="text-decoration: none;font-size: 24.0px;background-color: rgb(140,40,60);color: white;font-weight: bold;padding: 0.5em 1.0em;">Register!</a> </center> For more information, please refer to our earlier announcements: - [Contest Rules](https://qoj.ac/blog/qingyu/blog/1339) **Please read the rules carefully if you want to be a finalist!** We have a proctoring rule this year! - [TechNotes](https://qoj.ac/blog/qingyu/blog...
The contest is open to everyone. If you haven’t registered yet, join us today!

Full text and comments »

  • Vote: I like it
  • +360
  • Vote: I do not like it

128.
By maroonrk, history, 6 years ago, In English
About Rating Changes in AtCoder. TL;DR What if we introduce the followings: - You'll have a register-as-unrated button. You can switch rated and unrated only before opening a problem. - If you are registered as a rated participant, you'll get rated when you open a problem, even if you don't submit. Hello, community. Currently, your AtCoder rating changes only if you submit to the contest. This is also the case with Codeforces, so I think it's a standard. However, this scheme clearly has a flaw; you can leave the contest without submission to keep your rating. This implies you may get underrated because of those who didn't submit. You would say things like this can happen only if you are a newcomer, and the effect will be negligible in the long term. I generally agree with it, but sometimes even reds are affected by this issue. I know some people intentionally submit CE code to make them rated. At the same time, I know some people do the "Head to F" strategy or similar things and sometimes don't m...
problem. - If you are registered as a rated participant, you'll get rated when youopen a problem

Full text and comments »

  • Vote: I like it
  • +630
  • Vote: I do not like it

129.
By KAN, 9 years ago, translation, In English
Codeforces Round #476 (Div. 2) [Thanks, Telegram!] Hi everyone! <img src="/predownloaded/bf/c1/bfc15c5c56f3e421cc2799e5e1e0273cac1e3605.jpg" alt="digital resistance" title="digital resistance" style="float:right; margin: 0 1em 1em 1em; width:30%"/> Tomorrow, [on the April 25-th, 2018 at 17:35 UTC](http://www.timeanddate.com/worldclock/fixedtime.html?day=25&month=4&year=2018&hour=20&min=35&sec=0&p1=166) we are holding [contest:965]! The round will be rated for the second division participants, members with higher rating can take part out of competition. I give the floor to [user:MikeMirzayanov,2018-04-24] to announce the round: _This round opens a series of thanks-rounds to those who significantly supported Codeforces in the crowdfunding campaign for the 8th anniversary. Although Telegram is not explicitly present on the list of donators, for us this is the first and most important friend. We express our gratitude to Telegram and personally to Pavel Durov for the constant support and send regards from programming contest com...

Full text and comments »

  • Vote: I like it
  • +764
  • Vote: I do not like it

130.
By Arpa, history, 13 months ago, In English
GTOI: Graph Theory for Olympiad in Informatics <img src="https://algoritmiacademy.com/wp-content/uploads/2025/10/ChatGPT-Image-Oct-11-2025-06_09_15-PM.png" style="width: 30%; float: right; margin: 0 1.0em 1.0em 1.0em;"> Hello Codeforces! We're excited to announce **GTOI: Graph Theory for Olympiad in Informatics**, a free, community-driven book designed specifically for competitive programming. Why it's important and different: - **Completely Free & Open Source**: High-quality knowledge, accessible to everyone. - **Massive Coverage**: It covers from the fundamentals like _DFS_, _BFS_ to advanced topics like _Heavy-Light Decomposition_ and _Min-Cost Max-Flow_. - **Contest-Ready Code**: Short, fast C++ snippets ready for you to use in a contest. <center> <br> <iframe width="560" height="315" src="https://www.youtube.com/embed/G4Wp3FlY6JI?si=OR0_4T_oJhfPAfeQ" title="YouTube video player" frameborder="0" allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture; web-sha...
- **Completely Free & Open Source**: High-quality knowledge, accessible to everyone.

Full text and comments »

  • Vote: I like it
  • +86
  • Vote: I do not like it

131.
By dreamoon_love_AA, 12 years ago, In English
If you ask me how to improve your algorithm competition skill, I will give you the link of this blog. In recent one year, I don't know why but there are many people sending messages to me for asking similar problems. So I decide to create this blog. In the beginning, I must say, you may feel disappointed after reading this blog. Because I don't have any special tips. My study method has wasted me many many time. There are some basic points I think you have known. 1. **Practice, practice, and practice.** I take so many time to think and solve problems. I think I do it 5 hours a day on average. 2. **Make friends with many awesome people.** I know many awesome people. For example, [user:arosusti,2015-02-24], [user:kelvin,2015-02-24], peter50216([user:0O0o00OO0Oo0o0Oo,2015-02-24]), [user:seanwu,2015-02-24], [user:Shik,2015-02-24], [user:takaramono,2015-02-24], [user:tmt514,2015-02-24], ... If I have some problems that I can't solve in few weeks, I can almost get solution from my friends. Then I say what I do for training myself. When I do problems. There are two possi...
because they don't open for all people.)

Full text and comments »

  • Vote: I like it
  • +516
  • Vote: I do not like it

132.
By tibinyte2006, history, 4 years ago, In English
CodeTON Round 3 (Div. 1 + Div. 2, Rated, Prizes!) Hello, Codeforces! Or, as we like to say in Romania: Nu îmi amintesc să fi adresat întrebări, Codeforces! I am glad to finally invite you to participate in [contest:1750], which will start on [contest_time:1750]. You will be given **8** problems and **2 hours and 30 minutes** to solve them. It is greatly recommended to read all the problems, **statements are short and straight to the point**. I would like to thank: - [user:Artyom123,2022-10-31] for prodigious coordination. - [user:AquaMoon,2022-10-31], [user:mejiamejia,2022-10-31], [user:ugly2333,2022-11-05], [user:Ecrade_,2022-10-31] for huge help in preparation and authoring one of the tasks. - [user:errorgorn,2022-10-31] for being a VIP-tester. - [user:Lemur95,2022-10-31], [user:Gheal,2022-10-31], [user:Perpetually_Purple,2022-10-31], [user:Everule,2022-10-31], [user:IacobTudor,2022-10-31], [user:andrei_boaca,2022-10-31], [user:lucri,2022-10-31], [user:AlperenT,2022-10-31], [user:Kuroni,2022-10-31], [user:pra...
_The Open Network (TON) is a fully decentralized layer-1 blockchain designed to onboard billions of

Full text and comments »

  • Vote: I like it
  • +552
  • Vote: I do not like it

133.
By Ormlis, history, 3 years ago, translation, In English
XVIII Open Olympiad in Informatics (Unrated, Online Mirror, IOI rules) Hi everybody, In a few days there will be a Moscow Open Olympiad. This olympiad is prepared by Moscow Olympiad Scientific Committee that you may know by Moscow Olympiad in Programming, Moscow Team Olympiad, and Megapolis Olympiad (rounds <a href="https://codeforces.me/blog/entry/21185">327</a>, <a href="https://codeforces.me/blog/entry/23309">342</a>, <a href="https://codeforces.me/blog/entry/43615">345</a>, <a href="https://codeforces.me/blog/entry/47769">376</a>, <a href="https://codeforces.me/blog/entry/50613">401</a>, <a href="https://codeforces.me/blog/entry/54350">433</a>, <a href="https://codeforces.me/blog/entry/55201">441</a>, <a href="https://codeforces.me/blog/entry/57981">466</a>, <a href="https://codeforces.me/blog/entry/58229">469</a>, <a href="https://codeforces.me/blog/entry/61638">507</a>, <a href="https://codeforces.me/blog/entry/62440">516</a>, <a href="https://codeforces.me/blog/entry/65433">541</a>, <a href="https://codeforces.me/blog/entry/65768">5...
XVIII Open Olympiad in Informatics (Unrated, Online Mirror, IOI rules), Hi everybody, In a few days there will be a Moscow Open Olympiad. This olympiad is prepared by, In a few days there will be a Moscow Open Olympiad. This olympiad is prepared by Moscow Olympiad, The Open Olympiad consists of the most interesting and difficult problems proposed by our authors

Full text and comments »

  • Vote: I like it
  • +305
  • Vote: I do not like it

134.
By 300iq, 8 years ago, translation, In English
Codeforces Round #530 Hello everybody! Now the winter SIS (Summer Informatics School) is taking place, and we, as part of the parallel A+ with its teachers, have prepared a complete Codeforces Round. The round will happen at [contest_time:1098] and will last for 2.5 hours. There will be 6 problems in each division. The tasks of the round were invented and prepared by [user:300iq,2019-01-04], [user:scanhex,2019-01-04], [user:cookiedoth,2019-01-04], [user:allrats,2019-01-04], [user:osaaateiasavtnl.,2019-01-04], [user:Qlukva,2019-01-04], [user:Forestryks,2019-01-04], [user:Dimon,2019-01-04], [user:LordVoldebug,2019-01-04], [user:romanovsavelij,2019-01-04], [user:golub,2019-01-04], [user:ismagilov.code,2019-01-04],[user:alexey_kuldoshin,2019-01-04], [user:LadyPython,2019-01-05], [user:UnstoppableSolveMachine,2019-01-05] under the guidance of teachers [user:izban,2019-01-04], [user:VArtem,2019-01-04], [user:_meshanya_,2019-01-04], [user:pashka,2019-01-04]. Also thanks for testing [user:isaf27,2019-0...

Full text and comments »

  • Vote: I like it
  • +645
  • Vote: I do not like it

135.
By djm03178, 2 years ago, In English
Unreasonable delay for viewing submissions UPD: I'm bringing this up again, because I think this is a serious issue that's been bothering us for months already and I really want a proper explanation from the admins. Please [user:MikeMirzayanov,2024-11-20], don't just look over this. It's causing a huge inconvenience for many normal users. --------------------------------- I don't know since when this has been like this, but now it seems Codeforces has exclusive delay policy for submission pages. For example, try to open [submission:286905356] [submission:286913842] [submission:286925333] [submission:286943910] [submission:287014608] these pages in 5 separate tabs (open one in each second). If it's not only me, it will go like this: - 1st tab: opens immediately - 2nd tab: waits for 10 seconds and then opens - 3rd tab: waits for 20 seconds and then opens - 4th, 5th tab: immediately goes to the "Oops! Probably Codeforces can't be reached right now or your Internet connection is broken." page If you open the same ...
seems Codeforces has exclusive delay policy for submission pages. For example, try toopen, For example, try to open [submission:286905356] [submission:286913842] [submission:286925333, If you open the same submission page multiple times, the only difference is that all of them

Full text and comments »

  • Vote: I like it
  • +392
  • Vote: I do not like it

136.
By Noam527, history, 6 years ago, In English
Problem Likeability Feature Proposal -------- The feature to "star" or "favorite" a problem already exists; if you go to the problemset archive, you can choose to mark any problem as favorite. Same holds for marking any contest. Unfortunately, it seems the only use for this feature, is so one could revisit his favorite problems in the future &mdash; you can't view the favorite problems of other participants. I think this feature can be easily extended to something more meaningful. Maintain for each problem, the number of accounts who liked it (now referred to as the likeability of the problem). Then implement the option to filter (or sort) problems by their likeability (hopefully filtering problems by likeability could be combined with sorting by the number of people solved, so that people could find their own difficulty level). Same could go for contest likeability. Pros -------- - I think this can mainly help beginners. I hope that people who try out competitive programming for the first time, ...
marked it. This is open for discussion of course, but I think Mike would have better expertise in that, - I believe this will improve the CF problemset as a source of practice, which is probably a main, Everything is open for discussion. You're welcome to throw in more pros, cons or side notes.

Full text and comments »

  • Vote: I like it
  • +506
  • Vote: I do not like it

137.
By BitByBit123, 3 months ago, In English
Suspicious Master yql0991666 Update on 8/18/2026: [user:yql0991666,2026-08-18] have cheated to become a Master. How can he still not be banned? Update: Congratulations to [user:yql0991666,2026-08-18], the CHEATER is disabled! Good job, Mike! I, [user:BitByBit123,2026-08-10], suspect that [user:yql0991666,2026-08-18] is a cheater. I would like to report some suspicious behaviors and request an investigation. # Update on 8/18/2026 [user:yql0991666,2026-08-18], could you explain [387437964](/contest/2257/submission/387437964 "Submission 387437964 by yql0991666") [387437988](/contest/2257/submission/387437988 "Submission 387437988 by yql0991666") how can you write 1.6KB code in 3 seconds? Looking at the code for Problem E, what kind of person would write such a long definition on a single line (the fourth line)? If you interpret this as a way to make the code more compact (by consolidating lines), then why are the assignment statements on lines 19 through 24 separated? The only explanation is that...
Source:

Full text and comments »

  • Vote: I like it
  • +423
  • Vote: I do not like it

138.
By zscoder, history, 7 years ago, In English
Valentine's Day Contest 2020 Hello everyone! Will you be single and bored during Valentine's Day? Never fear, as [user:zscoder,2020-02-06] is here to cure your boredom. I would like to invite you to Valentine's Day Contest 2020, which will take place on [Friday, February 14, 2020 at 12:30 GMT](https://www.timeanddate.com/worldclock/fixedtime.html?iso=20200214T2030&p1=122&ah=3&am=30). The contest is unofficial and unrated, but the quality of most (if not all) of the problems are comparable to problems from a Codeforces round. I am the author of all problems. The contest format will be IOI format, which means that each problem is worth $100$ points, and there are subtasks for each problem. There will be no time penalty. The problems are **not sorted in increasing order of difficulty**. Unlike IOI, you are allowed to use any templates or notes you have. There are **7 problems** to be solved in **3.5 hours**. There is an interactive problem, so feel free to learn about them [here](https://codeforces.me/...

Full text and comments »

Announcement of Valentines Day Contest 2020
  • Vote: I like it
  • +564
  • Vote: I do not like it

139.
By MikeMirzayanov, 10 years ago, translation, In English
Codeforces: Domains For Groups Hello! Are you missing something new? I have something to please you. Regularly I host some events &mdash; Olympiads, onsites, and eventually, examinations and tests for students. On the one hand, Codeforces already offers a unique functionality &mdash; groups, the integration with Polygon, the possibility of choosing tasks from the archive and so on. But it doesn’t enough! ### Domains for groups Here is an example of such a group. It is open for all &mdash; join it and look: http://example.contest.codeforces.com ##### Domain Now when you are editing a group, you can specify its subdomain (from 3 to 20 alphanumeric characters, starts with a letter). When you specify the domain, the group will be accessible by a link http://yourgroupdomain.contest.codeforces.com. According to this link, the following is correct: * Nothing extra will be displayed &mdash; the site contains only the information about competitions and blogs of your group and nothing else. * A...
Here is an example of such a group. It is open for all — join it and look: http

Full text and comments »

  • Vote: I like it
  • +609
  • Vote: I do not like it

140.
By codetiger927, history, 5 years ago, In English
My Quest to Answer the Ultimate Question Through Machine Learning: If a hamster was born in aquarium, does it become a fish? `If a hamster was born in aquarium, does it become a fish?` &mdash; Rotavirus 2021 When the hour hand is way past twelve and the sky is dark, I often find myself pondering about this question, alone. Of course, a hamster is a hamster, and it cannot just become a fish right? But then again, if its mother gave birth to it inside an aquarium, then who's to say the hamsters didn't acquire a critical mutation that gifted them the ability to breathe underwater, transforming them into fish? I would be awake at 3 am in the morning, frustrated and defeated by this cruel dilemma that I cannot seem to solve. But, Rotavirus must know, right? After all, he was the person that proposed this rhetorical question, so he must have the answer to his own question! If I could just ask him, maybe, just maybe... Yet fate cheated me once again: Codeforces has permanently banned Rotavirus &mdash; I can no longer ask him. All I have left are only pieces of clues and hints scattered around his commen...
BUT, I actually did find a new source to retrieve a lot more of Rotavirus' comments in the famous, f = open("comments.txt", "ab"), ~~~~~ f = open('comments.txt','rb'); fout = open('comments_cleaned.txt','w'); lines

Full text and comments »

  • Vote: I like it
  • +508
  • Vote: I do not like it

141.
By Nathan4, history, 23 months ago, In English
What Did 2024 Look Like for You on Codeforces? Hello Codeforces, hope you're having a good time- In a blink of an eye, it is December again, and we're close to saying goodbye to 2024. I loved seeing my yearly reports on different apps at the end of each year, such as how many songs I listened to or how many shorts I've liked. So now I'm bringing you [**Codeforces Yearly Review**](https://nathanchen.me/projects/cf_review/index.html), which shows you your journey on Codeforces over the past year. ![ ](https://i.ibb.co/wJ5CK9x/Screenshot-2024-12-05-at-17-58-03.png) To start your journey, you only have to `cin >> your_handle` and specify your timezone, which is used for finding your late cate solve. <spoiler summary="Example"> ![ ](https://i.ibb.co/8df5ccG/Screenshot-2024-12-05-at-17-59-59.png) </spoiler> After this, it will start fetching data. This usually takes around 2 seconds, though longer if you solve more (e.g., [user:tourist,2024-12-05] took around 4 seconds). The speed here also depends on Codeforces serve...
I open-sourced the codes for this website on [GitHub](https://github.com

Full text and comments »

  • Vote: I like it
  • +357
  • Vote: I do not like it

142.
By Dominater069, 11 months ago, In English
IICPC Global Codefest 2026 Hello! Registrations for IICPC Global Codefest 2026 are opening soon. This is the first global edition of India's largest offline competitive programming competition. **About IICPC Codefest** IICPC (Intercollegiate Informatic and Competitive Programming Camp) is an academic and industry-backed organization focused on identifying, evaluating, and nurturing high-potential students in competitive programming, algorithms, and computer science fundamentals through rigorously designed, large-scale competitive examinations and camps. We organize Codefest, a multi-stage competitive programming competition conducted across India. This year, we are opening participation to international students from 50+ countries. **The prelims is individual participation, and online for international students. The deadline for registration is 15th January, 23:59 IST**. <img src="https://i.ibb.co/bRJt7y44/codefest-banner.png" height="50"> **Competition Structure** Prelims &mdash; Janua...
- Open to students from India and eligible international countries

Full text and comments »

  • Vote: I like it
  • +306
  • Vote: I do not like it

143.
By MikeMirzayanov, 8 years ago, translation, In English
Codeforces Round #547 (Div. 3) Hello, Codeforces! I am pleased to invite you to [contest:1141], which will start on [contest_time:1141]. Everyone whose current rating is strictly less than 1600 is invited to participate officially. All others can take part out of the competition. It so happened that the schedule of this month is not replete with rounds (coordinators, we hope for you!). Therefore I decided to partially correct the situation. All the problems of this round were invented and prepared by me on the last day of [Hello Muscat Programming Bootcamp 2019] (/blog/entry/63298) and on flights from Muscat to St. Petersburg. I even specially noted the time for preparation: for the current moment (the problems are ready for testing) I spent about 6 hours on their preparation, including inventing some of the problems. I really like working on problems, this is something at the intersection of creativity and programming. I really hope you enjoy the result of my work. <center> <br/> <img src = "/predownload...
, solutions will be judged on preliminary tests, and after the round it will be a 12-hour phase ofopen

Full text and comments »

  • Vote: I like it
  • +809
  • Vote: I do not like it

144.
By platelet, 3 years ago, In English
CodeTON Round 5 Editorial ### [problem:1842A] <spoiler summary="Tutorial"> Let's view it as when monsters $x$ and $y$ fight, their health changes into $\max(x-y,0)$ and $\max(y-x,0)$ respectively. So any monster with $0$ health is considered dead. Therefore, a player loses when the health of his monsters are all $0$. Notice that $\max(x-y,0)=x-\min(x,y)$ and $\max(y-x,0)=y-\min(x,y)$. Therefore, after each step, the sum of the health of monsters decrease by the same amount for both players. Therefore, we only need to know $\sum a_i$ and $\sum b_i$ to determine who wins. If $\sum a_i > \sum b_i$, Tsondu wins. Else if $\sum a_i < \sum b_i$, Tenzing wins. Else, it is a draw. </spoiler> <spoiler summary="Code"> ~~~~~ #include <iostream> using namespace std; int main() { ios::sync_with_stdio(false), cin.tie(nullptr); int T; cin >> T; while (T--) { int n, m, a[50], b[50]; long long sumA = 0, sumB = 0; cin >> n >> m; for (int i = 0; i < n;...
problem and $k$ right nodes representing intervals $[i,i+1]$. - The source node is connected to each

Full text and comments »

  • Vote: I like it
  • +573
  • Vote: I do not like it

145.
By Um_nik, history, 4 years ago, In English
MIT Mystery Hunt Disclaimer: This blog is not about competitive programming; you probably will not learn anything about algorithms and data structures. In other words, it doesn't qualify for [this initiative](https://codeforces.me/blog/entry/110840), but I want to give a link to it anyways because I think it's cool. I love solving problems. No, seriously. I LOVE it. The mindset described in [this blog](https://codeforces.me/blog/entry/91114) is 100% how I feel. But it is not constrained to competitive programming problems. I loved math problems for a much longer time, and physics was somewhere there. But I also love solving puzzles. And playing puzzle games on the computer (well, on consoles). And participating in intellectual games. I am not as good in them as in cp, but it was never about being good for me, I just love the process. And I think that there might be some people with a similar love for puzzles among competitive programmers, this is why I decided to write this blog on CF <s>and no...
the link will not open, the hunt just ended and I don't think the site was totally transformed into, Intrigued, I open [the recording of the broadcast](https://youtu.be/15Wyj_-PG9I?t=13192). They are, This story starts around 1 pm (in my timezone) on Saturday. I open the puzzle and see 12 small grid

Full text and comments »

  • Vote: I like it
  • +356
  • Vote: I do not like it

146.
By graknlabs, 6 years ago, In English
Grakn Forces 2020 “Codeforces… assemble!” <center> <img alt="grakn" src="https://grakn.ai/assets/svg/logo.svg" style="float:right; height: 50px; margin: 10px; max-width:10%;"/> </center> We are thrilled to announce **Grakn Forces 2020**; hosted by Codeforces and sponsored by [Grakn Labs](https://vaticle.com/). Thank you to Codeforces for providing a world-class competition structure to partner with. We can’t wait to see what you all are capable of. This international competition consists of 1 round, lasting 2.5 hours. The contest will comprise 7-9 problems and will be in accordance with classic Codeforces rules. **Prizes:** - 1st place = 500 euros - 2nd place = 250 euros - 3rd place = 100 euros **Additional Prizes:** Top 50 receive: _Grakn Labs swag pack:_ - Stickers - Grakn Labs t-shirt Random 50 from 51-250 receive: _Grakn Labs swag pack:_ - Stickers - Grakn Labs t-shirt **About Grakn Labs** [Grakn Labs](https://github.com/graknlabs) is a team...
Graql is distributed as an [open-source technology](https://github.com/graknlabs), while Grakn

Full text and comments »

Announcement of Grakn Forces 2020
  • Vote: I like it
  • +464
  • Vote: I do not like it

147.
By soullless, history, 16 months ago, translation, In English
Codeforces Round 1037 (Div. 3) Hello, Codeforces! I am very excited to invite you to our contest [contest:2126], which starts on [contest_time:2126]. You will be given **7 problems** and **2 hours and 15 minutes** to solve them. The problems were authored by me, [user:__rose,2025-07-15], [user:Pishka12,2025-07-15], [user:Chalishkan,2025-07-15] and [user:I_HATE_MD_DM,2025-07-15] to solve and alter them. The round will be hosted by the rules of educational rounds (extended **ICPC**). Thus, all solutions will be judged on preliminary tests during the round, and after the round, there will be a **12-hour phase** of open hacks. After the open hack phase, all accepted solutions will be rejudged on successful hacks. Also, note that there is no score distribution — rank will be determined by number of problems solved, followed by penalty; wrong submissions will incur the usual penalty of 10 minutes, following the rules of educational rounds. [Remember](https://mirror.codeforces.com/blog/entry/59228) that only t...
-hour phase** of open hacks. After the open hack phase, all accepted solutions will be rejudged on

Full text and comments »

  • Vote: I like it
  • +525
  • Vote: I do not like it

148.
By MikeMirzayanov, 11 years ago, translation, In English
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 &mdash; 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 &mdash; see the table below. Now reaching the top positions will be harder; * the legendary grandmaster &mdash; the new title and color for those who reached the sky high rating 2900. The cold colors (gray, green, cyan an...
will be open!

Full text and comments »

  • Vote: I like it
  • +527
  • Vote: I do not like it

149.
By adamant, history, 15 months ago, In English
CP-Algorithms: Discord server, donation campaign and more Hi everyone! <img src="/predownloaded/82/15/821540e8f87d8a2b2d468377aacbba80b0aa1623.png" style="float:right;" width=100px> It was a while since I [posted](https://codeforces.me/blog/entry/135081) last update about **[CP-Algorithms](https://cp-algorithms.com)**. As a general reminder, it is a community project that [started off](https://codeforces.me/blog/entry/13198) in 2014 by [user:RodionGork,2025-08-23] as a translation of [e-maxx](http://e-maxx.ru/), a Russian go-to resource at the time by [user:e-maxx,2025-08-23] for learning core competitive programming algorithms. Since then, CP-Algorithms grew quite a lot (which also prompted a rename from original project name `e-maxx-eng`) and includes a lot of new, original articles, and a lot of translated articles were enhanced and/or extended or even completely rewritten. In this blog, I would like to share a bunch of updates about the site, to make sure it's still in the collective memory &#128517; ### New maintainers ...
We use [Open Source Collective](https://opencollective.com/cp-algorithms) as our fiscal host, so

Full text and comments »

  • Vote: I like it
  • +142
  • Vote: I do not like it

150.
By cry, 2 years ago, In English
Invitation to Codeforces Round 962 (Div. 3) <center> Hewwo Cowodeforcers! ------------------ </center> [user:sum,2024-07-04] and I are overjoyed to welcome you to participate in [contest:1996] on [contest_time:1996]. This contest is the last stop on our mission to problemset for every division. We hope you've been enjoying our stuff so far! The round will be hosted by rules of educational rounds (extended ICPC). Thus, solutions will be judged on preliminary tests during the round, and after the round, it will be a 12-hour phase of **open hacks**. After open hacks all accepted solutions will be rejudged on successful hacks. You will be given **7 problems** and **2 hours and 15 minutes** to solve them. Note that the **penalty** for each wrong submission in this round is **10 minutes**. [Remember](https://codeforces.me/blog/entry/59228) that only the trusted participants of the third division will be included in the official standings table. As it is written by link, this is a compulsory measure for combating unsp...
**open hacks**. After open hacks all accepted solutions will be rejudged on successful hacks.

Full text and comments »

  • Vote: I like it
  • +423
  • Vote: I do not like it

151.
By PrinceOfPersia, 12 years ago, In English
Algorithm Gym :: Graph Algorithms Welcome to the new episode of [user:PrinceOfPersia,2015-01-31] presents: Fun with algorithms ;) You can find all the definitions here in the book "Introduction to graph theory", Douglas.B West. [cut] Important graph algorithms : DFS --- The most useful graph algorithms are search algorithms. DFS (Depth First Search) is one of them. While running DFS, we assign colors to the vertices (initially white). Algorithm itself is really simple : ~~~~~ dfs (v): color[v] = gray for u in adj[v]: if color[u] == white then dfs(u) color[v] = black ~~~~~ Black color here is not used, but you can use it sometimes. Time complexity : $O(n + m)$. #### DFS tree DFS tree is a rooted tree that is built like this : ~~~~~ let T be a new tree dfs (v): color[v] = gray for u in adj[v]: if color[u] == white then dfs(u) and par[u] = v (in T) ...
I only wanna put the source code here (EdmondsKarp):, This algorithm is a single source shortest path (from one source to any other vertices). Pay

Full text and comments »

  • Vote: I like it
  • +355
  • Vote: I do not like it

152.
By errorgorn, 3 years ago, In English
Confession: I sent problem H to goodbye Going to be 100% honest here, I sent problem H to goodbye. I feel really bad to authors of Goodbye 2023 for ruining their round, it seems the round would have been better by just removing H. As much as the community is out here roasting [user:74TrAkToR,2023-12-31], I also had a part to play in this contest. I wish to be as transparent as I can here without saying any classified information (apologies to [user:KAN,2023-12-31] and [user:74TrAkToR,2023-12-31] if anything here shouldn't be disclosed). To give some context, here is what went down in goodbye round from my perspective: - 13 days before contest: KAN asks me if I can source a 1E for goodbye. I asked traktor to send me the testing gym so that I could gauge how hard the 1E should be. He told me he will send me after he translates the statements. (UPD: Note that the IMO 1986 problem was already removed before this stage which is why a new 1E was needed, I never saw this IMO problem) - 11 days before contest: traktor send it...
coordinators to be more open. To be completely transparent, I am only a coordinator now because I, - 13 days before contest: KAN asks me if I can source a 1E for goodbye. I asked traktor to send me

Full text and comments »

  • Vote: I like it
  • +815
  • Vote: I do not like it

153.
By peltorator, 4 years ago, In English
Codeforces Month of Blog Posts (win $300) **TL;DR:** Write an interesting CodeForces blog post until February 15th and win $300. **UPD: Second place will receive $50.** **UPD2: Competition is over, The results are available [here](https://codeforces.me/blog/entry/113041).** I am a huge fan of CodeForces and specifically CodeForces blog posts! There are tens and hundreds of gems posted on this platform throughout the years. Thankfully, recently there was added the [catalog](https://codeforces.me/catalog) page where a lot of cool articles can be found. Personally, if I want to remember some classical algorithm, I would go to websites like [cp-algorithms](https://cp-algorithms.com/), but CodeForces is the place where new or rare stuff is born, where new points of view emerge. I think it is one of the most valuable functions of this website, and I would like to facilitate its growth. I know that many people have cool ideas in their minds that they came up with or maybe something that is known only in their community on ...
comments. I am open to any suggestions. Maybe, you think that 1.5 months is not enough for you, and you

Full text and comments »

  • Vote: I like it
  • +579
  • Vote: I do not like it

154.
By Imakf, history, 4 years ago, In English
Codeforces Global Round 24 Hello Codeforces!<img src="/predownloaded/2e/e2/2ee2f0f95f05aae6ca6f47812dae2dc2aabf277b.png" style="width: 200.0px;float: right;margin: 0 1.0em 1.0em 1.0em;max-width: 100.0%;max-height: 100.0%;"> On [contest_time:1764] we will host [contest:1764]. **Note the unusual time of the round.** It is the sixth round of a 2022 series of [Codeforces Global Rounds](https://codeforces.me/blog/entry/65002). The rounds are open and rated for everybody. The prizes for this round: - 30 best participants get a t-shirt. - 20 t-shirts are randomly distributed among those with ranks between 31 and 500, inclusive. The prizes for the 6-round series in 2022: - In each round top-100 participants get points according to the [table](https://pastebin.com/QT5sXEaT). - The final result for each participant is equal to the sum of points he gets in the four rounds he placed the highest. - The best 20 participants over all series get sweatshirts and place certificates. Thanks to XTX, which ...
/entry/65002). The rounds are open and rated for everybody.

Full text and comments »

Announcement of Codeforces Global Round 24
  • Vote: I like it
  • +513
  • Vote: I do not like it

155.
By I_love_Hoang_Yen, history, 6 years ago, In English
2020 ICPC Vietnam National Contest on Kattis Hi, This Sunday (Nov 15, 2020), there will be 2020 ICPC Vietnam National Contest on Kattis. This is the preliminary round before the Asia Vietnamese Regional. There will be online mirror after the contest. Details of **Online Mirror**: - Time: [1pm GMT+7](https://www.timeanddate.com/worldclock/fixedtime.html?msg=2020+ICPC+Vietnam+National+Online+Mirror&iso=20201115T13&p1=95&ah=5) - [Contest Link](https://vietnam-national20open.kattis.com/) Details of **Official contest**: - Time: [8am GMT+7](https://www.timeanddate.com/worldclock/fixedtime.html?msg=2020+ICPC+Vietnam+National+Contest&iso=20201115T08&p1=95&ah=5) - [Contest Link](https://vietnam-national20.kattis.com/) Problems prepared by: - [user:phamvanhanhgoldIOI2015,2020-11-15] - [user:chemthan,2020-11-15] - [user:I_love_Hoang_Yen,2020-11-15] - [user:I_love_tigersugar,2020-11-15] - [user:laoriu,2020-11-15] - [user:ll931110,2020-11-15] - [user:beo_chay_so,2020-11-15] - and some professors from Vietnam. ...
**UPD2**: The problems are now on [open Kattis](https://open.kattis.com/problem-sources/The%202020

Full text and comments »

  • Vote: I like it
  • +173
  • Vote: I do not like it

156.
By AlexSkidanov, history, 8 years ago, In English
Are we close to machines solving ICPC problems? Hi, all, I with few other folks at [NEAR](http://near.ai/blog) work on teaching machines to program. A particularly exciting sub-project of that is teaching machines to solve competitive programming problems. In this post I would like to give a quick overview of where the state of the art is today, what the major challenges are, why this is not a popular area of research, and how the CodeForces community can help to address some of the issues the program synthesis community is facing today. We also have a certain budged allocated for this project, and we are paying to the CodeForces members who help us with some data annotation challenges. We have paid more than $10k in our first two annotation projects, and are launching three more projects today. Scroll to the end if you are interested. Competitive programming as a benchmark ====================================== With the emergence of deep learning, neural networks started performing almost at a human level in many ta...
Open Challenges ===============

Full text and comments »

  • Vote: I like it
  • +336
  • Vote: I do not like it

157.
By buffering, history, 2 years ago, In English
Codeforces Global Round 26 Hello, Codeforces! We are pleased to announce Codeforces Global Round 26! Thanks to XTX Markets for supporting the initiative! In 2024, we are holding 4 such rounds. The series results will take into account the best 3 participations out of 4. On [contest_time:1984] we will host [contest:1984]. **<img src="/predownloaded/2e/e2/2ee2f0f95f05aae6ca6f47812dae2dc2aabf277b.png" style="width: 200.0px;float: right;margin: 0 1.0em 1.0em 1.0em;max-width: 100.0%;max-height: 100.0%;">** Codeforces Global Round 26 marks the second round in the 2024 series of Codeforces Global Rounds. These rounds are open and rated for everyone. The prizes for this round are as follows: - The top 30 participants will receive a t-shirt. - 20 t-shirts will be randomly distributed among participants ranked between 31 and 500, inclusive. The prizes for the 4-round series in 2024: - In each round, the top-100 participants get points according to the [table](https://pastebin.com/QT5sXEaT). - A part...
. These rounds are open and rated for everyone.

Full text and comments »

Announcement of Codeforces Global Round 26
  • Vote: I like it
  • +595
  • Vote: I do not like it

158.
By antontrygubO_o, 3 years ago, In English
[CONTEST OVER] MIT Informatics Tournament 2024 Spring Invitational **Update 2**: The Qualification Round has **officially concluded**! A huge thank you to our contestants for joining us and supporting this new initiative! Congratulations to the top 16 finalists who are advancing to the finals round (along with many more as we continue to confirm people's availability)! 1. [user:Rewinding,2024-04-24] 2. [user:ksun48,2024-04-24] 3. [user:Petr,2024-04-24] 4. [user:Geothermal,2024-04-24] 5. [user:mango_lassi,2024-04-24] 6. [user:hank55663,2024-04-24] 7. [user:ecnerwala,2024-04-24] 8. [user:MiFaFaOvO,2024-04-24] 9. [user:Kevin114514,2024-04-30] 10. [user:A_G,2024-04-30] 11. [user:Adam_GS,2024-04-24] 12. [user:Tourist,2024-04-24] 13. [user:FlowerOfSorrow,2024-04-24] 14. Matthew Allan 15. [user:uwu,2024-04-24] 16. [user:TLE,2024-04-24] At this time, the scoreboard has been finalized, and you can upsolve our problems / watch our video tutorials with the following links: - Finalized Scoreboard: [https://mitit.org/Contest/ViewScoreboar...
://mitit.org/Registration) application is now open on a first-come-first-serve basis!

Full text and comments »

  • Vote: I like it
  • +320
  • Vote: I do not like it

159.
By SlavicG, 3 years ago, In English
Codeforces Round 918 (Div. 4) Happy Holidays Codeforces! &#127877; [user:mesanu,2023-12-27], [user:flamestorm,2024-04-22] and I are very excited to invite you to [contest:1915]! It starts on [contest_time:1915]. The format of the event will be identical to Div. 3 rounds: - 5-8 tasks; - ICPC rules with a penalty of 10 minutes for an incorrect submission; - 12-hour phase of open hacks after the end of the round (hacks do not give additional points) - after the end of the open hacking phase, all solutions will be tested on the updated set of tests, and the ratings recalculated - by default, only "trusted" participants are shown in the results table (but the rating will be recalculated for all with initial ratings less than 1400 or you are an unrated participant/newcomer). We urge participants whose rating is 1400+ not to register new accounts for the purpose of narcissism but to take part unofficially. Please do not spoil the contest for the official participants. Only _trusted participants of the f...
phase of open hacks after the end of the round (hacks do not give additional points) - after the end

Full text and comments »

  • Vote: I like it
  • +503
  • Vote: I do not like it

160.
By djm03178, 2 years ago, In English
A proposal to change to open hacks on normal rounds Hacking has always been a hot issue and many people had mixed feelings on it. While I personally love the concept of hacking, I should agree that hacking on normal rounds is not very functional nowadays and is only causing several issues. - **The concept of rooms is heavily luck-based.** Depending on one's luck, there may be 0 to several submissions that can be hacked, and it is unfair to give several hundreds of free points to those who get a jackpot room. Even for the ones who submitted a wrong solution that passes pretests, it requires luck for them to be hacked by someone else so that they can realize that the solution was wrong and resubmit. - **Image blurring is not effective.** Although by the rules using OCRs to convert the images to texts is prohibited, there is no way to know if one is using them or not. In the old days, even if someone uses them we may have thought that it won't be very accurate, but nowadays OCRs are just too good and only the honest people who don't us...
A proposal to change to open hacks on normal rounds, - **Assign only a few (1-3) hours to open hacking.** I hope this phase to be somewhat concentrated, -contest open hacks to all rated rounds**, along with a few changes.

Full text and comments »

  • Vote: I like it
  • +237
  • Vote: I do not like it

161.
By ko_osaga, history, 8 years ago, In English
[GYM Training Contest] KAIST RUN Spring Contest 2019 (XIX Open Cup. GP of Daejeon) **Update 2019/06/12**: Me and [user:MikeMirzayanov,2019-06-11] managed to upload the Div.2 contest into Gym. Huge thanks him for the great system, and also a kind help! However, I decided not to just open it, but to give a training contest. The contest is scheduled in [June 14 Friday, 09:00 UTC.](https://www.timeanddate.com/worldclock/fixedtime.html?day=14&month=6&year=2019&hour=12&min=0&sec=0&p1=166) Even considering some obvious bias from the setter, I'm personally very proud of the Div.2 contest :D I hope you participate and share the same joy with us! (and of course, please don't cheat!) . . . . . . . . **Update 2019/06/05**: I managed to upload the Div.1 contest into Gym. Have fun! [https://codeforces.me/gym/102201](https://codeforces.me/gym/102201) Open Cup GP of Daejeon is scheduled at [2019/05/05 Sunday, 11:00 MSK](https://www.timeanddate.com/worldclock/fixedtime.html?msg=GP+of+Daejeon&iso=20190505T17&p1=3999&ah=5). Daejeon is a city whe...
[GYM Training Contest] KAIST RUN Spring Contest 2019 (XIX Open Cup. GP of Daejeon), * [XVIII Open Cup. GP of Korea](https://codeforces.me/blog/entry/57528) * [KAIST RUN Spring, Open Cup GP of Daejeon is scheduled at [2019/05/05 Sunday, 11:00 MSK](https://www.timeanddate.com

Full text and comments »

  • Vote: I like it
  • +88
  • Vote: I do not like it

162.
By bicsi, history, 6 days ago, In English
Optimal Incremental MST in 20 lines of code Hello Codeforces! Some of you might know `BottleneckTree.h` from [my KACTL fork](https://github.com/bicsi/kactl/blob/master/content/graph/BottleneckTree.h) (although it's a little obscure for an ICPC notebook; oh well). [user:freak93,2026-11-05] and I wrote it in 2021. The header says the complexity is "probably $O(\log n)$ amortized". It all started from a 2020 solution by [user:RestingRajarshi,2026-11-05] (more on that at the end). After about 6 years of on-and-off thinking about it, and with the help of Claude, we finally have an answer: it's not :). There are inputs where it takes $\Omega(\sqrt n)$ per operation. The good news is that a small change in the main loop fixes it, and this time we have a proof. We wrote a paper about it: [Incremental Minimum Spanning Trees on a Napkin](https://arxiv.org/abs/2611.05713). I think the structure is super elegant and short enough to be useful in contests, so I'm writing a blog about it. Prerequisites: none, really. It helps to know ...
Some open questions, if anyone is interested:

Full text and comments »

  • Vote: I like it
  • +291
  • Vote: I do not like it

163.
By zimpha, 6 years ago, In English
List of All Petrozavodsk Contests Like my last blog [List of All Open Cup Contests](https://codeforces.me/blog/entry/84466). I made this list for all contests from Petrozavodsk Training Camp, containing the standings, upsolving links and statements. The upsolving links of Petrozavodsk Summer 2020 are private, yandex.contest logins are needed. I will update the link if other sources found. And thanks to the efforts of [Baekjoon Online Judge](https://www.acmicpc.net/), most contests from winter 2015 to winter 2020 can be solved without private logins. For some of the rest contests, opentrains logins are needed. And for some of the rest contests, I found several other sources to virtual participant using [Virtual Judge](https://vjudge.net/), [Codeforces gyms](https://codeforces.me/gyms) and [Programmers club of PetrSU](http://acm.petrsu.ru/). For some of the rest contests, I could not find any public sources and maybe someone could help with it (I believe problems in Warsaw U Contests are from old POI or PA). ...
Note: the contests marked with `*` are used in Open Cup.

Full text and comments »

  • Vote: I like it
  • +483
  • Vote: I do not like it

164.
By alireza_kaviani, 12 months ago, In English
Repovive Opening Contest Hello everyone, We at Repovive are hosting our opening contest! Repovive is a new platform that aims to fill some of the gaps in access to high-quality competitive programming and CS education, especially for students who don’t have many local opportunities. Everything on Repovive is free, and our goal is to help improve the quality of CS education worldwide. Our opening contest will be held on Sunday, <s>November 23rd at 14:35 UTC</s> <s>November 30th at 14:35 UTC</s> **[December 14th at 14:35 UTC](https://www.timeanddate.com/worldclock/fixedtime.html?day=07&month=12&year=2025&hour=14&min=35&sec=0)**, in a Codeforces-style Div. 1 + Div. 2 format. Everyone is welcome to participate! Register at: https://repovive.com/contests Problem setters: [user:AmShZ,2025-11-16], [user:Muhammad-Ahmad,2025-11-16], [user:M.ZeeshanRashid,2025-11-16], [user:Muhammad-Saram,2025-11-16], [user:Amirrzwm,2025-11-16], [user:Kaleem_Raza_Syed,2025-11-16], [user:Shayan,2025-11-16], [user:Ghulam_Jun...

Full text and comments »

  • Vote: I like it
  • +190
  • Vote: I do not like it

165.
By bitset, 2 years ago, In English
[Bugged] Dynamic Bitsets in GCC **UPD1: The bug has been [fixed](https://gcc.gnu.org/bugzilla/show_bug.cgi?id=115399). I'll update the blog again when the fix is on Codeforces.** **UPD: Unfortunately, left / right shift is bugged and doesn't clear bits [properly](https://codeforces.me/blog/entry/129454?#comment-1157481). It should be fine for other operations, but use it at your own risk.** <spoiler summary="Original Blog"> Hello sirs, you might know that Boost has a dynamically sized bitset class, but did you know that GCC also has one? Turns out it's included in the tr2 folder. You can simply include the `<tr2/dynamic_bitset>` header, and use it as `std::tr2::dynamic_bitset`. **Yes, it works on Codeforces.** Here's a code example to count triangles in a graph ([abc258_g](https://atcoder.jp/contests/abc258/tasks/abc258_g)): <spoiler summary="Code"> ```cpp #include <bits/stdc++.h> I wonder if it's possible to get GCC to fix it... using namespace std; #include <tr2/dynamic_bitset> using namespa...
). You can view the source [here](https://github.com/gcc-mirror/gcc/blob/master/libstdc%2B%2B-v3

Full text and comments »

  • Vote: I like it
  • +514
  • Vote: I do not like it

166.
By tourist, 5 years ago, In English
SNWS 2022 streams Tune in at [twitch.tv/the__tourist](https://twitch.tv/the__tourist) at around [22:30 MSK, 11 Jan 2022](https://www.timeanddate.com/worldclock/fixedtime.html?msg=touristream:+SNWS+R1&iso=20220111T2230&p1=3396) to watch me solving [SnarkNews Winter Series 2022 Round 1](https://contest.yandex.com/snws2022/contest/23957/enter) live! First I will do the round competitively without much interaction, and I'll be up for discussing the problems on stream afterwards. SnarkNews Winter/Summer Series (SNWS/SNSS) is organized by [user:snarknews,2022-01-11] and consists of 5 rounds. Each round is a virtual 6-problem 80-minute contest open for 10 days. The series is open to all, but problem statements are in Russian only. On stream, I'll read the problem statements automatically translated to English. To make the stream more fun and for easier understanding of what will be going on, you're welcome to do the round yourself beforehand! If you don't understand Russian, you can also compete using au...
of 5 rounds. Each round is a virtual 6-problem 80-minute contest open for 10 days. The series is

Full text and comments »

  • Vote: I like it
  • +243
  • Vote: I do not like it

167.
By 74TrAkToR, history, 3 years ago, translation, In English
Codeforces Round #905 (Div. 1, Div. 2, Div. 3) Hello, Codeforces! We are happy to invite you to our experimental round for three divisions, which will take place at [contest_time:1887]. <b>Please note the non-standard start time for the round</b>. Each division will have 5-7 tasks. The round will be held according to the Codeforces rules and will be rated for all three divisions. A few changes regarding the ratings of participants in this competition: <ul style="list-style-type:square"> <li>In Div.3 the rating of participants is less than 1600. </li> <li>In the Div.2 ranking, participants range from 1600 to 2099. </li> <li>In Div.1 the rating of participants is no less than 2100.</li> <li><b>Please note</b> that after [contest:1884] the rating will not be recalculated until the end of this competition. </li> </ul> Let us note that two team Olympiads will be held in parallel on this day and the rounds are based on their tasks: <ul style="list-style-type:square"> <li> XXI Moscow Team Olympiad, high school stud...
elimination contest for All-Russian Team Olympiad. * III Open Team Olympiad UMSh in programming

Full text and comments »

  • Vote: I like it
  • +506
  • Vote: I do not like it

168.
By Crysfly, history, 3 months ago, In English
UOJ Prime Round 2026 & UOJ Challenge #1 [UOJ Prime Round 2026](https://uoj.ac/contest/112) will be held at [10:00 AM on Saturday, August 8 (UTC +8)](https://www.timeanddate.com/worldclock/fixedtime.html?iso=20260808T1000&p1=33)! The contest will last for 672 hours (28 days). [UOJ Challenge #1](https://uoj.ac/contest/113) will be held at [10:00 AM on Sunday, August 9 (UTC +8)](https://www.timeanddate.com/worldclock/fixedtime.html?iso=20260809T1000&p1=33)! The contest will also last for 672 hours (28 days). UOJ Prime Round has already been mentioned in a [previous blog post](https://gezhiyuan.blog.uoj.ac/blog/9779). It will bring together problems from on-site contests over the past year that were solved by almost nobody during the contests and have received relatively few post-contest submissions. As for UOJ Challenge, [user:Gellyfish,2026-08-08] happened to have an interesting problem that did not seem to fit particularly well anywhere else, so we thought we might as well release it alongside UOJ Prime Round for eve...
* Official documentation and tutorials: https://hull.aberter0x3f.top/ * GitHub open-source

Full text and comments »

  • Vote: I like it
  • +22
  • Vote: I do not like it

169.
By Zanite, history, 2 years ago, In English
Invitation to TLX Regular Open Contest #39 <img src="/predownloaded/40/0e/400e9c64e89b0d5af898014b9c7372fec74eb544.png" style="height: 200.0px;" /> <img src="/predownloaded/2d/30/2d30c17aba8882b75b0b9b0aa7c222a519bcc7ba.png" style="height: 150.0px;float: right;margin: 0 2.0em 2.0em 2.0em;max-width: 100.0%;max-height: 100.0%;" /> We are excited to invite you to **TLX Regular Open Contest #39!** Key details: - Contest links: [TLX](https://tlx.toki.id/contests/troc-39) - Time: [25th October 2024, 13:20 UTC](https://www.timeanddate.com/worldclock/fixedtime.html?msg=TLX+Regular+Open+Contest+%2339&iso=20241025T1320&p1=1440) - Writers: [user:joelgun14,2024-10-23], [user:joshjms,2024-10-23], [user:JvThunder,2024-10-23], [user:MetalPower,2024-10-23], [user:Nevll,2024-10-23], [user:yz_,2024-10-23], [user:Zanite,2024-10-23] - Duration: 2 hours - Problems: 8 - Scoring distribution: **150 — 200 — 350 — 450 — 600 — 700 — 700 — 750** We would like to thank: - [user:Pyqe,2024-10-23] and [user:yz_,2024-10-23] ...
Invitation to TLX Regular Open Contest #39, =TLX+Regular+Open+Contest+%2339&iso=20241025T1320&p1=1440), We are excited to invite you to **TLX Regular Open Contest #39!**

Full text and comments »

  • Vote: I like it
  • +180
  • Vote: I do not like it

170.
By errorgorn, 19 months ago, In English
1/phi Halving in Interactive Tree Problems Thanks to [user:toxicpie9,2025-04-22] for proofreading and emotional support. Recently, I was thinking about JOISC 2025 Space Thief. And there is a part where you need to do divide and conquer on a tree, where you need to split the edges of the tree into two components where the edges are both connected. Basically, we consider an interactive problem on a tree where there is a hidden edge. We are allowed to ask queries of the form $(v,N_v)$ where $v$ is a vertex of the tree and $N_v$ is a set of neighbouring edges of $v$. Then the query returns to us whether the hidden edge is in the subtree of one of $N_v$ when we root the tree at $v$. We maintain a set of edges that the hidden edge can be in. In each query, we try to split the set of edges into two parts and ask a query to separate them. In the worst case, we replace the set of edges by the larger component. Let $R$ be the maximum ratio of the larger component. In [this blog](https://codeforces.me/blog/entry/120446)...
## Open Problems, #### (**Open Problem 2**) Can we improve the bound $\frac{1}{\varphi} < \tilde R < \frac{2}{3

Full text and comments »

  • Vote: I like it
  • +208
  • Vote: I do not like it

171.
By Radewoosh, history, 7 years ago, In English
Blogewoosh #7 Hello, codeforces! Long time no see, right? So maybe it's a good idea to try to return to my blogs slowly. This time the blog will be about a trick, which usually isn't necessary to solve a task, but can be useful to make implementation much more comfortable. Let's look at [this](https://codeforces.me/contest/932/problem/F) problem. It is about some DP on a tree in which we have to use convex hull trick to improve the complexity. The task requires merging two convex hulls with "smaller to bigger" trick. I recommend you to read the statement before reading the rest of the blog (and the [editorial](https://codeforces.me/blog/entry/57796) if you don't know how to solve it). [cut] $ $ So, how to merge two convex hulls? If we keep them in something like the set from C++, then we can just take every element from the smaller one and try to add it to the bigger one. Unfortunately, adding one element in this way requires some ifology and care. It's hard to implement it, especiall...
some Open Cup a long time ago if I'm not mistaken, but I'm unable to find it). We have to keep a

Full text and comments »

  • Vote: I like it
  • +697
  • Vote: I do not like it

172.
By -is-this-fft-, 4 years ago, In English
[Tutorial] My way of understanding Dinitz's ("Dinic's") algorithm **Part 1: [Tutorial] My way of understanding Dinitz's ("Dinic's") algorithm** [Part 2: [Tutorial] Minimum cost (maximum) flow](https://codeforces.me/blog/entry/105330) [Part 3: [Tutorial] More about minimum cost flows: potentials and Dinitz](https://codeforces.me/blog/entry/105658) #### Introduction My philosophy on writing blogs is that I only write blogs when I feel that I have something new and interesting to contribute. This is usually not the algorithm itself, of course, but it can be that I recently found or heard of a new perspective or I figured out a way to explain something in a new way. This is in contrast to my dear colleagues at GeeksForGeeks who write the most low-effort (and often wrong) tutorial on everything and then sit at the top of Google results using their somehow world-class SEO. This is one such case. I have an idea how to explain Dinitz's algorithm in a way I haven't heard of before (but it is not very hard to come up with, so this is...
Throw out some edges in $G_f$ so that we are left with a DAG $D$ where $s$ is a source and $t$ is, in other words, it is the amount of flow entering $s$ from an "outside source". It is possible to

Full text and comments »

  • Vote: I like it
  • +280
  • Vote: I do not like it

173.
By purplesyringa, history, 2 years ago, In English
Please improve QoL for blogs I'm pretty sure I've spent more time writing blogs than contests on Codeforces. Over time, I've found plenty of rough edges. So this is a plea to the Codeforces team to fix them. I'm effectively going to say "please redo everything" over dozens of paragraphs, but I'll hopefully make the steps to the solution tangible and clear. If this is deemed way too ambitious, few improvements are better than none. [cut] <!-- --> ## Publication time So I write a post in the Codeforces UI, save a draft, update it a few times, think it's ready, and publish it. I open my brand new post and see: > ### Totally not a useless post > By [user:purplesyringa,2024-09-24], history, 3 days ago, In English Okay, wait, "3 days ago"? Oh, right, that's when I saved the first draft. Now people open the post, see "3 days ago", see 0 upvotes, and what do they think? That's right, they think it's garbage because no one's voted positive, so they skip the article. Maybe not everyone's like tha...

Full text and comments »

  • Vote: I like it
  • +370
  • Vote: I do not like it

174.
By indy256, 13 years ago, In English
Dynamic Programming Optimizations Several recent problems on Codeforces concerned dynamic programming optimization techniques. The following table summarizes methods known to me. <table> <tr> <th>Name</th> <th>Original Recurrence</th> <th>Sufficient Condition of Applicability</th> <th>Original Complexity</th> <th>Optimized Complexity</th> <th>Links</th> </tr> <tr> <td><small>Convex Hull Optimization1</small></td> <td nowrap><small>$dp[i] = min_{j<i}\{dp[j]+b[j] \star a[i]\}$</small></td> <td nowrap>$b[j] \geq b[j+1]$<br/><small><s>optionally</s>&nbsp;$a[i] \leq a[i+1]$</small></td> <td nowrap>$O(n^2)$</td> <td nowrap>$O(n)$</td> <td nowrap><small>[1](https://web.archive.org/web/20181030143808/http://wcipeg.com/wiki/Convex_hull_trick) [2](https://cp-algorithms.com/geometry/convex_hull_trick.html) [3](https://codeforces.me/blog/entry/63823)<br/>[p1](/contest/319/problem/C)</small></td> </tr> <tr> <td><small>Convex Hull Optimization2</small></td> <td nowrap><small>$dp[i][j] = min_{k<j}{dp[i-1][k]+b...
Open questions:

Full text and comments »

  • Vote: I like it
  • +388
  • Vote: I do not like it

175.
By tmwilliamlin168, history, 6 years ago, In English
My CP Course "Zero to Hero" is now open for pre-registration! Having had a ton of experience with CP, I have decided that I could share my knowledge the best with the world by making a course! This course currently has lessons designed for people of many levels, from newbies to low masters. Currently, I have opened pre-registration. I'm currently just trying to get an idea of how many people would be interested in such a course (and also to catch possible bugs on the website). Here is the course website: http://course.williamlin.io/ 100 lucky winners who pre-register will be given beta access to the course for free! Pre-registration won't be open for long though, so be sure to do it quick! **Update:** Thanks to every who pre-registered! The pre-registration assessment proved to be tough, and we decided to offer spots for beta access even for those who did not pass the test! Look out for an email from [email protected] for your decision letter, as well as solutions and more opportunities to gain beta access to the course! **Up...
My CP Course "Zero to Hero" is now open for pre-registration!, -registration won't be open for long though, so be sure to do it quick!

Full text and comments »

  • Vote: I like it
  • +254
  • Vote: I do not like it

176.
By fchirica, 13 years ago, In English
Codeforces Round #225 — Editorial [problem:384A] ================== Usually, when you don’t have any idea how to approach a problem, a good try is to take some small examples. So let’s see how it looks for N = 1, 2, 3, 4 and 5. With C I noted the coder and with * I noted an empty cell. ![ ](http://s28.postimg.org/8z1d7k399/New_Bitmap_Image.png) By now you should note that answer is N ^ 2 / 2 when N is even and (N ^ 2 + 1) / 2 when N is odd. Good. Generally, after you find a possible solution by taking examples, you need to prove it, then you can code it. In order to proof it, one needs to do following steps: 1/ prove you can always build a solution having N ^ 2 / 2 (or (N ^ 2 + 1) / 2) pieces. 2/ prove that N ^ 2 / 2 (or (N ^ 2 + 1) / 2) is maximal number – no other bigger solution can be obtained. For proof 1/ imagine you do coloring like in a chess table. ![ ](http://s27.postimg.org/ysqhphx0z/New_Bitmap_Image.png) The key observation is that by placing all coders on black squares of tab...
For a reference solution, check [user:Endagorion,2014-01-21]'s AC source during contest.

Full text and comments »

  • Vote: I like it
  • +418
  • Vote: I do not like it

177.
By adamant, history, 4 years ago, In English
Arrow product: How to enumerate directed graphs Hi everyone! In this blog, I would like to present a somewhat novel concept in competitive programming, which is, while being relatively simple, allows us to enumerate directed graphs with specific type of strongly connected components. This allows us to easily and uniformly compute generating functions e.g. for acyclic digraphs or strongly connected digraphs. The formalism introduced here is also very intuitive at that. I initially wanted to make a problem based on the content of this blog to appear in today's round, but after some discussions we decided to exclude it, as the contest already had a sufficient amount of difficult problems. You may try the original problem **[problem:441297A]** via the [invitation link](https://codeforces.me/contestInvitation/4d42a205a747b194397bbabd35ab2e81f9793447). #### Prerequisites You are expected to be familiar with exponential generating functions, and the [exponential formula](https://en.wikipedia.org/wiki/Exponential_formula) for c...
DAGs with $n$ vertices and $k$ source vertices, divided by $n!$ (so it is EGF in terms of the number, of _marked_ source vertices, corresponding to the generating function $e^{ux}$, and of a directed, In the formula above, we choose $i$ out of $n$ vertices to be the source vertices in $\binom{n}{i

Full text and comments »

  • Vote: I like it
  • +245
  • Vote: I do not like it

178.
By adamant, 11 months ago, In English
Finding all primes up to half a billion in 83 ms Hi everyone! I was itching to apply SIMD in another problem, and this time my attention picked the following problem: --- **[Library Checker &mdash; Enumerate Primes](https://judge.yosupo.jp/problem/enumerate_primes)**. You are given $N$, $A$ and $B$. Find $\pi(N)$, and print all $p_{kA + B} \leq N$. It is guaranteed that $N \leq 5 \cdot 10^8$ and that the total number of primes to print is at most $10^6$. --- After some tweaking, I managed ([#336744](https://judge.yosupo.jp/submission/336744)) to reduce my time consumption in this problem to **83 ms** and memory consumption to **25 MiB**, which makes it a top-1 submission on the Library Checker. For comparison, the top-2 solution ([#148169](https://judge.yosupo.jp/submission/148169)) takes 172 ms and 15 MiB, meaning that what I describe here is a 2x improvement in terms of the running time. We can also compare it to what appears to be the state of the art of sieving, the [primesieve](https://github.com/kimwalisch/...
source code of my submission.

Full text and comments »

  • Vote: I like it
  • +375
  • Vote: I do not like it

179.
By -Morass-, history, 9 years ago, In English
Problem Topics Good Day to you! I've been asked to make some topic-wise list of problems I've solved. Even though I couldn't involve all problems, I've tried to involve at least "few" problems at each topic I thought up (I'm sorry if I forgot about something "easy"). I've alredy made such list once anyway I've tried to include more problems now &mdash; so here it is: <spoiler summary="aho"> http://www.spoj.com/problems/ADAJOBS/ URI 2226 (5) //[NICE][NUMBERS][DP] http://www.spoj.com/problems/SUB_PROB/en/ http://codeforces.me/contest/696/problem/D 8 http://www.spoj.com/problems/AHOCUR/ 5 //Aho-Corassic + DP https://www.codechef.com/problems/LYRC (5) //Sample aho-brute-force http://codeforces.me/problemset/problem/346/B //Proposed by [user:bradyawn,2019-08-03] </spoiler> <spoiler summary="automat"> 6861 [LA] //CYK UVA 10679 //Suffix Automat http://www.spoj.com/problems/STRMATCH/ //Suffix Automat &mdash; trie might do too http://www.spoj.com/problems/NSUBST...
2015-2016 CTU Open Contest: Chasing the Cheetah, http://codeforces.me/contest/3/problem/D (4) //?==) ..if open < 0: set max A-B to (

Full text and comments »

  • Vote: I like it
  • +428
  • Vote: I do not like it

180.
By Geothermal, history, 7 years ago, In English
Gauging Interest in Training Program Hi all! I'm currently considering opening up a competitive programming training program of some sort. The details are definitely still in the works, though, and I wanted to discuss some preliminary ideas with the community to get feedback on what would be most helpful (and on whether there would be any interest in this). I'm interested in starting a training program for three main reasons: - To make competitive programming more accessible to those without access to resources like college courses or training camps - To provide a space in which questions are encouraged and actively answered (especially since I think this generally isn't the case in the community at large) - To help competitive programmers build problem-solving skills and intuition, which I think aren't sufficiently emphasized by most contest training resources I think one of the most frustrating things about being a new (or even intermediate) competitive programmer is that it's generally pretty difficu...
- For a smaller group of people with more competitive programming experience, I'd beopen to

Full text and comments »

  • Vote: I like it
  • +376
  • Vote: I do not like it

181.
By chokudai, 3 years ago, In English
Thank you for participating in the AtCoder World Tour Finals 2022 English (translated by GPT-4): To AWTF2022 Contestants, Thank you so much for participating in the contest. I apologize for not being able to communicate much due to my inability to speak English. Did you enjoy the contest event? I look forward to seeing you again in Japan. To Everyone, With the conclusion of the topcoder open (TCO) and Google Code Jam (GCJ), and the decision to hold Meta Hacker Cup 2023 online, the only on-site contest in 2023 where anyone from around the world can participate and truly determine the world's best is the AtCoder World Tour Finals. I have participated in the topcoder open finals 5 times (Marathon division) and in the Google Code Jam finals once. Both tournaments were outstanding. From my experience as a competitive programmer, participating in these competitions has been significant, and I believe that this culture must continue. The AtCoder World Tour Finals is a budding event. Compared to TCO and GCJ, it has a shorter history, and th...
I have participated in the topcoder open finals 5 times (Marathon division) and in the Google Code, With the conclusion of the topcoder open (TCO) and Google Code Jam (GCJ), and the decision to hold

Full text and comments »

  • Vote: I like it
  • +474
  • Vote: I do not like it

182.
By Errichto, 5 years ago, In English
3 Hard Interactive Problems Hi. I think these are nice medium-hard interactive problems. I will discuss solutions in a stream today at https://www.twitch.tv/errichto. UPD, recording is here https://youtu.be/9oEihYrAR5kUPD and I added text solutions in this blog. P1. **Mostly A** &mdash; You're given two integers $N$ and $K$ ($N \leq 50\,000$, $K \leq 10$). You need to find a hidden string of length $N$ with lowercase English characters a-z. At most $K$ characters are different than 'a'. You can choose your own string of length $N$ and you will get info YES/NO whether your string is lexicographically smaller than the hidden one. There is no explicit limit on the number of queries. There's still some time limit (say, 2 seconds). Hard version: Minimize the number of queries. <spoiler summary="slow solution"> It seems reasonable to discover characters one by one from left to right. Let's say that we already know the prefix `raay` and we're looking for the fifth character. We can binary search it in $...
If you know the source of problems 1 or 3, please let me know.

Full text and comments »

  • Vote: I like it
  • +235
  • Vote: I do not like it

183.
By MinakoKojima, history, 11 years ago, In English
My sad story Teams advancing to 2016 WF Phuket in Asia have been announced recently. This announcement is undisputedly tantamount to a death sentence for me. I am the one waiting anxiously, refresh Dr. Hwang's blog everyday. But it seems that for years, our training was meaningless. I think many of us dedicate our passion to programming contests because we see them transparent, fair and without any corruption. And I also believe that as contestants, what we should do is only focus on the practice. And I thought those political business should never come to bother me one day. But sadly, it is my team who is going to become one of the sacrifices of a succession of the dissension. What happened so far ------------------ The quarrel between the Asia director and the local community is [a long story](http://blog.sina.com.cn/s/blog_b946da100101q21y.html) to tell. But it has never been as serious as it was in the past season. Now reflecting on this, I know on the surface everything is going okay...
exactly what we do, and now it is almost a open secret for us. If you guys have any opposition, you are, what we do, and now it is almost a open secrets for us. If you guys have any opposition, you are

Full text and comments »

  • Vote: I like it
  • +1310
  • Vote: I do not like it

184.
By Monogon, history, 5 years ago, In English
[Tutorial] Graph Potentials, Johnson's Algorithm, and Min Cost Max Flow In this tutorial I'll introduce potentials as it applies to directed graphs and discuss a few of its applications. I haven't seen many resources about this topic, so I decided to write one. Prerequisites: - Shortest path algorithms ([Dijkstra](https://cp-algorithms.com/graph/dijkstra.html) and [Bellman-Ford](https://cp-algorithms.com/graph/bellman_ford.html)) - For the Min Cost Max Flow section, you should be familiar with [Ford-Fulkerson](https://cp-algorithms.com/graph/edmonds_karp.html). But you can benefit from this blog with just the Johnson's Algorithm section if you're not familiar with flows. Introduction ------------------ For notation, let's say there is a weighted, directed graph $G=(V,E)$. Let $n=|V|$ and $m=|E|$. For simplicity, let's assume there are no loops or multiple edges between the same pair of nodes in the same direction. For an edge $u\to v$, we will use $w(u\to v)$ to denote its weight. Let's motivate the idea of a potential, so the definition d...
source and sink. Every edge $u\to v$ has a capacity $c(u\to v)$ and a cost $w(u\to v)$. A **flow** is

Full text and comments »

  • Vote: I like it
  • +387
  • Vote: I do not like it

185.
By Um_nik, history, 5 years ago, In English
Problem Database - Idea for a CP-related project I can sometimes see people doing some CP-related projects for their courses/portfolio/community, and I want to suggest an idea of such a project that would benefit me as a CodeChef Admin and all the problemsetters, I believe. Issue: There are a lot of problems on different platforms, and it is really hard to check if some problem was already used somewhere or not. Sometimes googling works, but most of the time I have to rely on my own experience and memory, which are far from perfect. It's hard to search for problems, because they usually have some kind of story, and the same problem can be formulated in a lot of different ways. Proposed solution: Create some kind of smart database, that will collect the problems from all known sources and will have some very smart search engine that would focus on the internal meaning of the problem, instead of how it is formulated. I have no idea how to do any of that :) I would assume that it would require some kind of very smart ML and a l...

Full text and comments »

  • Vote: I like it
  • +470
  • Vote: I do not like it

186.
By pani.natalia, 5 years ago, In English
700 contests. ruban's interview Please meet my today's guest Anatoly [user:ruban,2021-05-17], PhD in Physics and Mathematics, who yesterday participated in his 700th contest on Codeforces. ![ ](/predownloaded/7c/d8/7cd88780306e8b25e1ac72a6e7b5b2b47914f0d0.jpg) [cut] _._ _-Hello Anatoly_ -Hello Natalia _-Were you surprised by my message that you had taken more contests on Codeforces than anybody else?_ -No, I wasn’t. I knew it for sure. There have been only several occasions when I missed rounds because of high rating, I think, not many than 20-30. _-Do you feel something special about contests with the round number like 500th, 600th or this one 700th?_ -No, I wouldn't pay any attention if there were no interview. _-How did you start on Codeforces?_ -Since 2001 (long before Codeforces) I have coached the competitive programming team of [SibSUTIS](https://sibsutis.ru/en/) &mdash; Siberian State University of Telecommunications and Information Science and created problems for All...
_-What is the best source of knowledge?_ -The best source is communication with people who

Full text and comments »

  • Vote: I like it
  • +479
  • Vote: I do not like it

187.
By Mangooste, 3 years ago, In English
XVIII Open Olympiad in Informatics (2023-2024) Hello, Codeforces! We have started the qualification contest of the **Open Olympiad in Informatics**! The Open Olympiad in Informatics is one of the most prestigious and challenging olympiads for school students in Russia. Every year, the most experienced students from Russia and other countries participate in the final of the olympiad. Starting this year, the results of the Open Olympiad will also be taken into account for the selection of participants for the Russian national team in informatics at various international olympiads. The tasks for the olympiad are prepared by the Moscow Olympiad Scientific Committee that you may know by Moscow Team Olympiad, Moscow Olympiad for Young Students and Metropolises Olympiad (rounds [327](https://codeforces.me/blog/entry/21185), [342](https://codeforces.me/blog/entry/23309), [345](https://codeforces.me/blog/entry/43615), [376](https://codeforces.me/blog/entry/47769), [401](https://codeforces.me/blog/entry/50613), [433](https://codeforc...
XVIII Open Olympiad in Informatics (2023-2024), This year, we decided to make Open Olympiad actually open for all international participants. Now

Full text and comments »

  • Vote: I like it
  • +167
  • Vote: I do not like it

188.
By aropan, 8 years ago, translation, In English
9th BSUIR Open Programming Championship <div style="text-align: center; margin-bottom: 10px;"> <img src="http://fksis.bsuir.by/wps/wcm/connect/0b2ce08048f7551a8edcee2567d03bb3/1/photo_2019-02-26_16-25-55.jpg?MOD=AJPERES"/> </div> The results and upsolving of the semifinal are available at [link](https://official.contest.yandex.ru/bsuir2019/contest/12360/standings). Many thanks to all guys who made this contest for you: [user:hloya_ygrt,2019-03-20], [user:teleport,2019-03-20], [user:wilcot,2019-03-20], [user:ShavelV,2019-03-20], [user:rui-de,2019-03-20], [user:Vladik,2019-03-20], [user:vilcheuski,2019-03-20], [user:netman,2019-03-20], [user:tkach1024,2019-03-20] and [user:jklementseva,2019-03-21]. The **9th BSUIR Open Programming Championship** will be held from March 13 till April 25, 2019 (Minsk, Belarus). [cut] Undergraduates and postgraduates of BSUIR, students of other educational institutions, students from other universities and countries are invited to participate in the Championship. The competition wi...
9th BSUIR Open Programming Championship, Open BSUIR Programming Championship is held by the ACM rules. During the Championship, the teams

Full text and comments »

  • Vote: I like it
  • +248
  • Vote: I do not like it

189.
By maroonrk, history, 19 months ago, In English
What to be careful about when submitting your problems to other contests This is a story about my recent contest participation. Let's call the contest X. X was an international contest with online qualification rounds and the onsite Finals, with trip and hotel expenses covered by the organizer. In other words, X was a very important contest for me. Hoping to go to the Finals, I participated in the qualification round. However, when I opened the last problem, I immediately remembered that the exact same problem had previously been submitted to AtCoder. I also knew that the submitter of that problem was among the organizers of X. Let's call the author of that problem Y. I immediately messaged Y about this issue. At first, I thought that Y had simply forgotten that he had submitted the problem to me, but the situation was a bit more complicated. Y _did_ remember he had submitted the problem to me but still used it in another contest. Why? Because I had given him permission! To make things clear, let me show you the relevant chat log betw...

Full text and comments »

  • Vote: I like it
  • +308
  • Vote: I do not like it

190.
By ko_osaga, history, 6 years ago, In English
[Gym] XXI Open Cup. Grand Prix of Korea Hello! I'm happy to announce XXI Open Cup. Grand Prix of Korea. * Contest link: [https://official.contest.yandex.ru/opencupXXI/contest/20794/enter](https://official.contest.yandex.ru/opencupXXI/contest/20794/enter) * Contest time: 2020/10/11 Sunday, 17:00 Korea Standard Time (UTC+9). For external accounts, the contest is ready now. * Division 1 Problemsetters: [user:ainta,2020-10-09], [user:jh05013,2020-10-09], [user:kdh9949,2020-10-09], [user:ko_osaga,2020-10-09], [user:tlwpdus,2020-10-09]. * Division 2 Problemsetters: [user:Diuven,2020-10-11], [user:etaehyun4,2020-10-11], [user:jh05013,2020-10-09], [user:jihoon,2020-10-11], [user:kdh9949,2020-10-09], [user:ko_osaga,2020-10-09] * **Codeforces Gym**: [Division 1](https://codeforces.me/gym/102759) [Division 2](https://codeforces.me/gym/102760) Special thanks to [user:xiaowuc1,2020-10-09] for revising our English. List of relevant previous contests: * [XVIII Open Cup. GP of Korea](https://codeforces.me/blog/entry/575...
[Gym] XXI Open Cup. Grand Prix of Korea, * [XVIII Open Cup. GP of Korea](https://codeforces.me/blog/entry/57528) * [KAIST RUN Spring, Hello! I'm happy to announce XXI Open Cup. Grand Prix of Korea.

Full text and comments »

  • Vote: I like it
  • +279
  • Vote: I do not like it

191.
By DNR, 5 months ago, In English
So you're a proud ratist? Here's why that's problematic (GRAYtist v1.1 out now) Just kidding, I'm one too. <img src="https://raw.githubusercontent.com/welcome-to-the-sunny-side/graytist/main/public/wordmark.png?v=2" alt="GRAYtist" style="float:right; width:400px; height:auto; margin-left:24px; margin-bottom:8px;"> Introducing [GRAYtist](https://chromewebstore.google.com/detail/graytist/bflnfmllkbhilogfbdilcckpkfganelc), a browser extension that helps you filter out low-quality content from Codeforces. You might say: "B-b-but [user:DNR,2026-06-12], such a tool would surely spam some API calls or use some heavyweight classifier models! My potato PC couldn't handle it, right?!". Wrong. We instead use the principle of ratism ($P(\text{low rating} \iff \text{low quality}) \approx 1$) to optimize away all of that nonsense. <div style="clear:both;"></div> ### Features ##### 1. Filter blogs by author rank and title. - Don't want to see blogs from grays because they're annoying, and blogs from nutellas because they make you feel inferior? GRAYtis...
Source code can be found [here](https://github.com/welcome-to-the-sunny-side/graytist).

Full text and comments »

  • Vote: I like it
  • +295
  • Vote: I do not like it

192.
By avighnakc, history, 15 months ago, In English
OI Checklist: Virtual Contests with Real Medal Cutoffs Ever wanted to see how you’d score in CEOI 2024… as if you were actually there? With real medal cutoffs, percentiles, and your submissions auto-scored by subtasks: all just by entering your oj.uz username? Now you can. - Live demo: https://checklist.spoi.org.in/. (click on 'Try Demo') - GitHub (open source!): https://github.com/avighnac/oi-checklist/ ## What's inside - Precise tracking – mark problems as solved, partially solved, or assign an exact score out of 100. - Contest-based organization – problems grouped by Olympiad, year, and round. - Virtual contests – start any past contest with a live timer, track performance, and get an actual post-contest scoreboard. - Real historical data – medal type, rank, percentile — all based on the original contest results. - Auto-sync with oj.uz – past submissions automatically update your progress (for your entire checklist!) or in contest submissions for virtual contests. - Submission breakdown – see your score per subtask (in co...
- Live demo: https://checklist.spoi.org.in/. (click on 'Try Demo') - GitHub ( open source!): https, This is the modern, actively maintained, open-source successor.

Full text and comments »

  • Vote: I like it
  • +142
  • Vote: I do not like it

193.
By sammyuri, 6 months ago, In English
Spectral::Cup 2026 Round 2 (Codeforces Round 1100, Div. 1 + Div. 2) Editorial Thank you for participating in our round! We hope you enjoyed the problems as much as we enjoyed preparing them. <spoiler summary="Rate the contest!"> <spoiler summary="Quality"> - Absolute Cinema contest - Excellent contest - Good contest - Average contest - Bad contest - Horrible contest </spoiler> <spoiler summary="Difficulty"> - Trivial contest - Easy contest - Average contest - Hard contest - Impossible contest </spoiler> </spoiler> [problem:2229A] Idea by: [user:Intellegent,2026-05-23] Prepared by: [user:Intellegent,2026-05-23] Editorial by: [user:reirugan,2026-05-23] <spoiler summary="Hint 1"> Let $y$ denote the final position of all of the slimes. Then it is optimal to choose $x = y$ for every operation. </spoiler> <spoiler summary="Hint 2"> Let $\mathrm{mn}$ denote the minimum value in $a$, a...
] + aa[j]); } void finalise(ll *target, ll *source, ll b, int tsize) { for (int i = tsize; i > 0

Full text and comments »

  • Vote: I like it
  • +304
  • Vote: I do not like it

194.
By errorgorn, 13 months ago, In English
Congrats bribritt on becoming Singapore's new youngest LGM bro still has 3 more IOI and IMO attempts &#128128;&#128128;&#128128; <spoiler summary="By the way, I was wondering whether Singapore having 2 LGMs would make us the highest LGM per capita. It turns out no."> Note that here, I am doing it by max rating, instead of current rating. <div style="text-align:center;"> <img src="https://cdn.discordapp.com/attachments/752406106009239585/1423728259522105588/image.png?ex=68e15dc4&is=68e00c44&hm=a4ca2cc71c4482788e5915e40b71213a9a8d896fddd8594758c8d6b1eac663af&" style="width:50%;"> </div> In the chart above, I manually added one more LGM to Singapore. The error bars are what happens with $\pm 1$ LGM. Manually inspecting the above graph, we see that we should probably remove Antigua and Barbuda, and Samoa. Actually let's remove Cyprus (which I think <a class="rated-user user-red" href="/profile/Endagorion" title="International Grandmaster Endagorion">Endagorion</a> plausibly lives there) too from the plot so we can see everythin...
# Save to cache with open(CACHE_FILE, "w", encoding="utf-8") as f: json.dump

Full text and comments »

  • Vote: I like it
  • +257
  • Vote: I do not like it

195.
By Errichto, 7 years ago, In English
Bitwise operations 2 — popcount & bitsets Part 1 ([link](https://codeforces.me/blog/entry/73490)) introduces basic bitwise operations. This is part 2 and it's mainly about (in)famous bitsets and example problems. Also, see links to very useful advanced stuff at the bottom. EDIT: here's [video version](https://www.youtube.com/watch?v=jqJ5s077OKo&list=PLl0KD3g-oDOHpWRyyGBUJ9jmul0lUOD80) of this blog (on my Youtube channel). ### Built-in functions In C++, `__builtin_popcount(x)` returns popcount of a number &mdash; the number of ones in the binary representation of $x$. Use `__builtin_popcountll(x)` for long longs. There are also `__builtin_clz` and `__builtin_ctz` (and their long long versions) for counting the number of leading or trailing zeros in a **positive** number. Read more [here](https://www.geeksforgeeks.org/builtin-functions-gcc-compiler/). Now, try to solve these two simple tasks in $O(1)$, then open the spoiler to check the solution: <spoiler summary="Compute the biggest power of 2 that is a divisor o...
open the spoiler to check the solution:

Full text and comments »

  • Vote: I like it
  • +326
  • Vote: I do not like it

196.
By Pyqe, 3 years ago, In English
Invitation to TOKI Indonesian NOI Open Contest 2023 Hello Codeforces community, We are excited to invite you to **TOKI Indonesian NOI Open Contest 2023** — an online mirror contest for the Indonesian National Olympiad in Informatics. This national olympiad is one of the stages required for our students to qualify to represent Indonesia in the International Olympiad in Informatics (IOI). You may have seen our past open olympiads ([2015](https://codeforces.me/blog/entry/17924), [2016](https://codeforces.me/blog/entry/44892), [2017](https://codeforces.me/blog/entry/53037), [2018](https://codeforces.me/blog/entry/60263), [2019](https://codeforces.me/blog/entry/67967), [2020](https://codeforces.me/blog/entry/83514), [2021](https://codeforces.me/blog/entry/96689), [2022](https://codeforces.me/blog/entry/107378)), and you can check our past problems [here](https://tlx.toki.id/problems/problemsets?archive=osn). The contest is similar to IOI: 2 competition days (+ 1 trial session), each consisting of 3 IOI-style (partial, subtasks)...
Invitation to TOKI Indonesian NOI Open Contest 2023, /open)., The result of the open contest can be found on [our website](https://osn.toki.id/OSN2023/open, We hope we can conduct the open OI again, and see you next year!

Full text and comments »

  • Vote: I like it
  • +86
  • Vote: I do not like it

197.
By reirugan, 17 months ago, In English
Codeforces Round 1034 (Div. 3) Hello, Codeforces! ================== I am very excited to invite you to my first-ever contest, [contest:2123], which will start on [contest_time:2123]! In this contest, you will be given **2 hours and 15 minutes** to solve **7 problems**. The round will be hosted by the rules of educational rounds (extended ICPC). Thus, all solutions will be judged on preliminary tests during the round, and after the round, there will be a 12-hour phase of **open hacks**. After the open hack phase, all accepted solutions will be rejudged on successful hacks. Also, note that there is no score distribution &mdash; rank will be determined by number of problems solved, followed by penalty; wrong submissions will incur the usual penalty of **10 minutes**, following the rules of educational rounds. [As a reminder](https://codeforces.me/blog/entry/59228), only trusted participants of the third division will be included in the official standings table. This is a compulsory measure for combating unspo...
phase of **open hacks**. After the open hack phase, all accepted solutions will be rejudged on

Full text and comments »

  • Vote: I like it
  • +478
  • Vote: I do not like it

198.
By E869120, 3 years ago, In English
JOI Open Contest 2023 Hello everyone! [JOI Open Contest 2023](https://contests.ioi-jp.org/open-2023/index.html) will be held from [Saturday, August 5, 04:00 UTC](https://www.timeanddate.com/worldclock/fixedtime.html?msg=JOI+Open+Contest+2023&iso=20230805T04&p1=1440) to [Sunday, August 6, 04:00 UTC](https://www.timeanddate.com/worldclock/fixedtime.html?msg=JOI+Open+Contest+2023&iso=20230806T04&p1=1440). You can start any time and the duration is basically 5 hours. Note that the duration becomes shorter if you start after [Saturday, August 5, 23:00 UTC](https://www.timeanddate.com/worldclock/fixedtime.html?msg=JOI+Open+Contest+2023&iso=20230805T23&p1=1440), i.e. less than 5 hours before the contest ends. There will be **3 tasks**, and the maximum score for each task is **100 points**. Since this is an IOI-style contest, **there may be some subtasks**. Each submitted source program must be written **only in C++**. Problem statements will be provided both in Japanese and in English. You can find more deta...
JOI Open Contest 2023, IOI-style contest, **there may be some subtasks**. Each submitted source program must be written

Full text and comments »

  • Vote: I like it
  • +229
  • Vote: I do not like it

199.
By Ormlis, history, 2 years ago, In English
Codeforces Round 980 (Div.1, Div. 2) Hello, Codeforces! We're glad to invite you to take part in Codeforces Round 980 (Div.1, Div. 2), which will start on [contest_time:2023]. **Note the unusual time of the round.** Each division will have 6 problems and 2 hours to solve them. The round will be held according to the Codeforces rules and will be rated for both divisions. The problems were authored and prepared by [user:Mangooste,2024-10-18], [user:Tikhon228,2024-10-18], [user:adepteXiao,2024-10-18], [user:Artyom123,2024-10-18], [user:sevlll777,2024-10-18], [user:yunetive29,2024-10-18], [user:glebustim,2024-10-18], [user:Endagorion,2024-10-18], [user:isaf27,2024-10-20] guided by [user:Ormlis,2024-10-18] and Helen Andreeva. The round is based on XXII Moscow Team Olympiad, high school students competition based in Moscow that is an elimination contest for All-Russian Team Olympiad. Also thanks to the authors of the Olympiad whose problems were not included in the round : [user:vaaven,2024-10-18], [user:TeaTime,2024-10-1...
**UPD2:** Due to the official competition source codes of other participants will not be available

Full text and comments »

  • Vote: I like it
  • +255
  • Vote: I do not like it

200.
By Zlobober, 11 years ago, translation, In English
Codeforces update: contests and problemsetters Hi everybody! Hope you liked our [Revolution of Colors and Titles](/blog/entry/20638). Maybe you even have took part in a contest in new status. The last round have set an incredible record: 8000 participants! And I'm glad to tell you that there was no single technical issue during the round time! Consider the 15-minute delay as a part of our evil plan for setting up a new record :) I'm glad to tell that Codeforces team is able not only to tune colors and formulas, but also to work on new features for you. You may see on [contests](/contests) page that there is a list of authors for each of the rounds! Moreover, in profile of a person there is now an entry called "problemsetting" that allows you to see the list of all contests in whose preparation a person took a part. <center> <a href="http://i.imgur.com/3mul76p.png"><img src="http://i.imgur.com/3mul76p.png" /></a> <br /> [user:Endagorion,2015-10-03] looks like this. </center> [cut] Let's clarify what do we mean by tak...

Full text and comments »

  • Vote: I like it
  • +673
  • Vote: I do not like it

201.
By Pajaraja, history, 17 months ago, In English
Olympicode Open Olympiad Hello everyone! We'd like to announce an olympiad style contest that will be held on our new Olympicode Judge &mdash; the Olympicode Open Olympiad! **What is the difficulty level and format of the contest?** The contest is envisioned as a warm-up for the IOI and similar international olympiads. So, it will be two days with 3 IOI-style tasks and the contest will be 5h. It will probably, on average, easier than the IOI, but it should still be fun for OI-level participants. **When is the contest?** The first day will be on [Saturday, July 5 2025 at 09:30 UTC](https://www.timeanddate.com/worldclock/fixedtime.html?msg=Olympicode+Open+Olympiad+Day+1&iso=20250705T0930&p1=1440&ah=5), while the second day will be on [Sunday, July 6 2025 at 09:30 UTC](https://www.timeanddate.com/worldclock/fixedtime.html?msg=Olympicode+Open+Olympiad+Day+2&iso=20250706T0930&p1=1440&ah=5). **Which programming languanges are allowed?** The only supported languages will be C++ and Python. **...
Olympicode Open Olympiad, /worldclock/fixedtime.html?msg=Olympicode+Open +Olympiad+Day+1&iso=20250705T0930&p1=1440&ah=5), while the

Full text and comments »

  • Vote: I like it
  • +156
  • Vote: I do not like it

202.
By smax, 3 years ago, In English
[Tutorial] Simulating Cost Flow You can also read this on my blog: https://mzhang2021.github.io/cp-blog/simulating-cost-flow/ Thanks to [user:gabrielwu,2023-07-19] for proofreading. --- This post assumes knowledge of [min/max cost flow](https://en.wikipedia.org/wiki/Minimum-cost_flow_problem) and a rough understanding of the high-level methods for solving (successive shortest path and cycle canceling). Knowledge of specific algorithms and implementation details are not expected. Also solutions to some problems will use [Aliens trick](https://web.archive.org/web/20210511092429/http://www.serbanology.com/). --- The cost flow problem is a well-known problem in literature that a whole slew of competitive programming problems can be formulated as. Unfortunately, competitive programming problems typically have constraints set too high for directly running even the most state of the art cost flow algorithm. However, in certain problems the flow network will have a very specific setup that allows us to figure ...
Note that in the cycle cancelling paradigm, there is no concept of source and sink, but you can

Full text and comments »

  • Vote: I like it
  • +293
  • Vote: I do not like it

203.
By rng_58, history, 9 years ago, In English
World Finals 2017 statistics and my prediction **1. Tsinghua** (Win: 40%, Gold: 90%, Medal: 100% after some rounding) - CF max: 3441, 3203, 2967 (agg = 3516) - Open Cup: 1, 1, 11, 9 (median = 5) - China Final: 1 - MIPT: 1, 1, 1, 2, 4, 1, 4 **2. Warsaw** (Win: 15%, Gold: 75%, Medal: 95%) - CF max: 3122, 2962, 2826 (agg = 3237) - Open Cup: 2, 3 (median = 2.5) - Petrozavodsk: 4, 2, 4, 3, 2, 2, 1, 2 **3. SPb ITMO** (Win: 15%, Gold: 50%, Medal: 90%) - CF max: 2880, 2870, 2860 (agg = 3104) - Open Cup: 7, 3, 2, 1, 13, 1, 2, 1, 3, 7, 13, 8, 8, 12, 3, 2, 1, 12 (median = 3) - Petrozavodsk: 4, 1, 3, 1, 6, 5, 3, 7, 5 - MIPT: 6, 2, 3, 1, 5, 2, 1 **4. SPb SU** (Win: 10%, Gold: 40%, Medal: 85%) - CF max: 3170, 2951, 2936 (agg = 3281) - Open Cup: 9, 21, 18, 5, 3, 4, 9, 9, 6, 1, 2, 2, 7, 1, 4, 23, 20, 4 (median = 5.5) - Petrozavodsk: 7, 3, 6, 5, 8, 1, 4, 5, 1 - MIPT: 2, 4, 2, 3, 1, 10, 8 **5. Seoul** (Win: 5%, Gold: 40%, Medal: 85%) - CF max: 3174, 2919, 2760 (agg = 3250) - Open Cup: 4, failed, 4 (median = 4) ...
, 2967 (agg = 3516) - Open Cup: 1, 1, 11, 9 (median = 5) - China Final: 1 - MIPT: 1, 1, 1, 2, 4, 1, 4, - CF max: 2761, 2637, 2273 (agg = 2870) - Open Cup: 2, 17, failed, 7 (median = 12) - MIPT: 5, 5, - CF max: 2772, 2341, 2220 (agg = 2808) - Open Cup: 11, 15, 21, 10, 2 (median = 11), - CF max: 2900, 2637, 2540 (agg = 2981) - Open Cup: Equivalent to 2.5 in NAIPC, - CF max: 2920, 2566, 2338 (agg = 2965) - Open Cup: 21, 3 (median = 12) - China Final: 6, - CF max: 2925, 2908, 2703 (agg = 3100) - Open Cup: Equivalent to 12.5 in NAIPC - Barcelona: 3, 2, - CF max: 3073, 2429, 2006 (agg = 3082) - Open Cup: 6, 8, 16 (median = 8) - MIPT: 14, 9, 10, 16, - CF max: 3122, 2962, 2826 (agg = 3237) - Open Cup: 2, 3 (median = 2.5) - Petrozavodsk: 4, 2, 4, - CF max: 3174, 2919, 2760 (agg = 3250) - Open Cup: 4, failed, 4 (median = 4)

Full text and comments »

  • Vote: I like it
  • +365
  • Vote: I do not like it

204.
By adamant, history, 4 years ago, In English
Duality in linear programming. Part 1 — definition and construction Hi everyone! Previously I [wrote](https://codeforces.me/blog/entry/98334) about theoretical grounds of "aliens trick". Specifically, I introduced the concept of the Lagrangian duality and explained its connection with the trick. Today I want to elaborate a bit more on the concept of dual problems and their applications to linear programming as well as to common problems in competitive programming. I initially wanted to also write about some applications in competitive programming problems, but given that the introduction is already quite lengthy, I decided to leave it for another blog, while using most common and well-known theoretical examples here, focusing more on how to construct and interpret dual problems to begin with, rather than how to use it in contests. I think, it is a crucial first step towards using the duality in actual programming challenges. #### Prerequisites It is highly recommended to have some general understanding of basic mathematical optimization...
Here's an example that highlights all possible variations ([source ](https://laurentlessard.com

Full text and comments »

  • Vote: I like it
  • +250
  • Vote: I do not like it

205.
By Pyqe, 13 months ago, In English
Invitation to TLX Regular Open Contest #42 <img src="/predownloaded/2d/30/2d30c17aba8882b75b0b9b0aa7c222a519bcc7ba.png" style="width: 400.0px;float: right;margin: 0 1.0em 1.0em 1.0em;max-width: 100.0%;max-height: 100.0%;" /> Hello, Codeforces! We're excited to invite you to **TLX Regular Open Contest #42!** Key details: - Contest links: [TLX](https://tlx.toki.id/contests/troc-42) - Time: [13th October 2025, 13:05 UTC](https://www.timeanddate.com/worldclock/fixedtime.html?msg=TLX+Regular+Open+Contest+%2342&amp;iso=20251013T1305&amp;p1=1440) - Writer: [user:Pyqe,2025-10-10] - Duration: 2 hours 30 minutes - Problems: 7 - Scoring distribution: **100 — 200 — 300 — 350 — 500 — 700 — 800** I would like to thank: - [user:tzaph_,2025-10-10] for the coordination. - [user:rama_pang,2025-10-10], [user:user202729,2025-10-10], and [user:Kinon,2025-10-10] for their help in testing the problems and giving feedback. - [user:fushar,2025-10-10] for the TLX platform. Please register for the contest and I encou...
Invitation to TLX Regular Open Contest #42, =TLX+Regular+Open+Contest+%2342&iso=20251013T1305&p1=1440), We're excited to invite you to **TLX Regular Open Contest #42!**

Full text and comments »

  • Vote: I like it
  • +73
  • Vote: I do not like it

206.
By gotexans, 5 years ago, In English
Technocup 2022 — Elimination Round 1 and Codeforces Round #749 (Div. 1+Div. 2) Hi all! This weekend, at [contest_time:1583] we will hold [contest:1586]. It is based on the problems of Technocup 2022 Elimination Round 1 that will be held at the same time. **Note the unusual start time of the contest.** Technocup is a major olympiad for Russian-speaking high-school students, so if you fall into this category, please register at <a href="https://technocup.mail.ru/">Technocup website</a> and take part in the Elimination Round. The Div. 1 + Div.2 edition is open and rated for everyone. Register and enjoy the contests! The problems were written and prepared by [user:Tlatoani,2021-10-16], [user:golions,2021-10-16], [user:rabaiBomkarBittalBang,2021-10-16], [user:qlf9,2021-10-16], and me. We would like to express our thanks for [user:antontrygubO_o,2021-10-16], [user:isaf27,2021-10-16], and [user:KAN,2021-10-16] for reviewing our problems and being great coordinators! Huge thanks to the following users for testing our round: [user:kefaa2,2021-10-16]...
The Div. 1 + Div.2 edition is open and rated for everyone. Register and enjoy the contests!

Full text and comments »

  • Vote: I like it
  • +460
  • Vote: I do not like it

207.
By -is-this-fft-, history, 5 years ago, In English
[Thought process] Solving 1503C — Travelling Salesman Problem #### Preface When the problem came out, someone [asked](https://codeforces.me/blog/entry/89337) for an explanation of how people come up with such solutions. I wanted to write this blog even before that, but I've just been busy. Anyway now, two months later, I finally had the time to put this blog together. But the reason I really wanted to write this blog is that the solution to [problem:1503C] has a very much non-obvious greedy solution. From reading beginners' comments, it seems that a lot of people have this implicit belief that greedy algorithms are invented by _guessing_: for example, _guessing_ an order in which to process things, _guessing_ how to process things and then maybe proving correctness if you have time (but really skipping it, because who cares, right?). I think some contest sites even perpetuate this idea by presenting a greedy algorithm in the editorial without any kind of proof or explanation where this comes from. Even here, you may have tutor...
for a proof that can be adapted and the source of this intuititon).

Full text and comments »

  • Vote: I like it
  • +368
  • Vote: I do not like it

208.
By MikeMirzayanov, 12 years ago, translation, In English
Codeforces: results of 2014 <img src="http://assets.codeforces.com/images/statistics-2014/snowman-en.png" style="float:right; margin:0 1em 1em 1em;"/> Hello 2015! Hello Codeforces! It seems it is time to take stock. Frankly, I was almost feared to start summing statistics of 2014. In 2013 Codeforces showed rapid growth so that it would not be surprising to look bad on the background of 2013. Certainly not! I was pleasantly surprised by the statistics and reports! Just below is a list of major events and achievements of Codeforces over the year. For you, it's just a list, but please note &mdash; every item includes hard work of multi-day Codeforces team, writers of problems, the organizers of contests and tournaments, problem testers and volunteers. Yay! Together we have done all of this: * introduced Codeforces API * added (and sometimes improved) all Andrew [user:andrewzta,2015-01-03] Stankevich contests * Codeforces supported mode to work as iframe-widget, and Codeforces helped Google to run https...

Full text and comments »

  • Vote: I like it
  • +934
  • Vote: I do not like it

209.
By BigBag, 10 years ago, translation, In English
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...

Full text and comments »

  • Vote: I like it
  • +557
  • Vote: I do not like it

210.
By awoo, history, 7 years ago, translation, In English
Educational Codeforces Round 85 [Rated for Div. 2] Hello Codeforces! On [contest_time:1334] [contest:1334] 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.me/blog/entry/51208">blog post</a>. This round will be **rated for the participants with rating lower than 2100**. It will be held on extended ICPC rules. The penalty for each incorrect submission until the submission with a full solution is 10 minutes. After the end of the contest you will have 12 hours to hack any solution you want. You will have access to copy any solution and test it locally. You will be given **6 or 7 problems** and **2 hours** to solve them. The problems were invented and prepared by Roman [user:Roms,2020-04-09] Glazov, Adilbek [user:adedalic,2020-04-09] Dalabaev, Vladimir [user:vovuh,2020-04-09] Petrov, Ivan [us...

Full text and comments »

  • Vote: I like it
  • +361
  • Vote: I do not like it

211.
By DrSwad, history, 7 years ago, In English
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 ...
maximum possible xor of the elements of some subset of $S?$ [Link to the source ](https, to the source](https://codeforces.me/blog/entry/60003)

Full text and comments »

  • Vote: I like it
  • +425
  • Vote: I do not like it

212.
By Proof_by_QED, 19 months ago, In English
Codeforces Round 1017 (Div. 4) # Good Morning/Afternoon/Evening/Night Codeforces ---------- <center> <br/> <img src="https://i.ibb.co/dZM4Rgm/1000015885-removebg-preview.png" alt="1000015885-removebg-preview" border="0"><br/> This is Orangutini Ananasini Emoji </center> ---------- [user:cry,2025-04-07] and I are overjoyed to welcome you to participate in [contest:2094] at [contest_time:2094]. **Note the unusual time of the round**. You will be given $2$ hours and $15$ minutes to solve $8$ problems. The round will be hosted by rules of educational rounds (extended ICPC). Thus, solutions will be judged on preliminary tests during the round, and after the round, it will be a 12-hour phase of **open hacks**. After open hacks all accepted solutions will be rejudged on successful hacks. Note that the **penalty** for each wrong submission in this round is **10 minutes**. Also, **note the [rule restricting AI use](https://codeforces.me/blog/entry/133941)!!!** If you are caught using AI, your submissio...
**open hacks**. After open hacks all accepted solutions will be rejudged on successful hacks.

Full text and comments »

  • Vote: I like it
  • +344
  • Vote: I do not like it

213.
By AlexLuchianov, 5 years ago, In English
[Tutorial] Binary lifting ### The classic Problem The most common application of binary lifting is the following: "Let $G$ be a rooted tree with $N$ nodes. For $Q$ queries of the form $(K, V)$ we want to find the $K$-th ancestor of $V$ in the tree." One simple, yet quite inefficient way of solving this problem is to build for every node an edge towards its direct ancestor. Then, in order to solve a query we simply have to traverse $K$ edges. This approach has complexity $O(NQ)$. We can try improving it by adding some "jump-edges". ![Fig 1](https://i.imgur.com/ualhJEj.png) A jump-edge is simply an edge that starts from a node and is not directed towards its parent, but towards an arbitrary ancestor. These jump-edges will allow us to traverse large regions of edges in a single operation. Let's start by building jump-edges from *each* node towards its $2$-nd ancestor, $4$-th ancestor, $8$-th ancestor and so on. Note that in the above figure only a *subset* of these jump-edges is visible since otherwis...
Source code implementing this approach can be found [here](https://cses.fi/paste

Full text and comments »

  • Vote: I like it
  • +291
  • Vote: I do not like it

214.
By lnishan, 11 years ago, In English
An awesome list for competitive programming! This is a project I started from late January 2016. My motive is that: Although there's fantastic information out there, I think they're still spread all over the place. Therefore, in my opinion it would probably be cool if there's an [awesome list](https://github.com/sindresorhus/awesome) for competitive programming! ( *It's now featured on the main list!* ) I'm actively updating the list here: [https://github.com/lnishan/awesome-competitive-programming](https://github.com/lnishan/awesome-competitive-programming) # Awesome Competitive Programming [![Awesome](https://cdn.rawgit.com/sindresorhus/awesome/d7305f38d29fed78fa85652e3a63e154dd8e8829/media/badge.svg)](https://github.com/sindresorhus/awesome) A curated list of awesome `Competitive Programming`, `Algorithm` and `Data Structure` resources. Created with a view to connecting people to information, this list below contains a complete collection of all the fantastic resources I've collected over the course of my 11...
## Open Courses > Consider beginning your competitive programming journey with these awesome, ### Open Courses for Algorithms and Data Structures

Full text and comments »

  • Vote: I like it
  • +438
  • Vote: I do not like it

215.
By awoo, history, 7 years ago, translation, In English
Educational Codeforces Round 71 [Rated for Div. 2] Hello Codeforces! On [contest_time:1207] [contest:1207] 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.me/blog/entry/51208">blog post</a>. This round will be **rated for the participants with rating lower than 2100**. It will be held on extended ICPC rules. The penalty for each incorrect submission until the submission with a full solution is 10 minutes. After the end of the contest you will have 12 hours 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 invented and prepared by Roman [user:Roms,2019-08-06] Glazov, Adilbek [user:adedalic,2019-08-06] Dalabaev, Vladimir [user:Vovuh,2019-08-06] Petrov, Ivan [user:Bl...

Full text and comments »

  • Vote: I like it
  • +258
  • Vote: I do not like it

216.
By ekzhang, history, 6 years ago, In English
Online Workspace for Codeforces Problems Hello all, Like you, I enjoy solving Codeforces problems on the go. However, sometimes I am not working on my computer with all my environment and setup. There are many automated problem parsers and test runners to help make solving Codeforces problems painless, but they all require a complicated installation process. About a year ago, I was introduced to [CS Academy](https://csacademy.com/), which I thought had an amazing interface for solving problems. It shows the problems and your code side-by-side, and you can automatically run your program on the example test cases. Also, there is auto-saving in case you accidentally close your window. Why can't we have this for Codeforces? I couldn't find anything on the web that was easy to set up and fun to use, so I made my own online workspace at [wkspace.herokuapp.com](http://wkspace.herokuapp.com/). ![Screenshot of wkspace](https://i.imgur.com/2wT2u6x.png) Here are some features: - No sign-up or installation required - P...
**Note:** The code is open source and available at https://github.com/ekzhang/wkspace.

Full text and comments »

  • Vote: I like it
  • +419
  • Vote: I do not like it

217.
By awoo, history, 5 years ago, translation, In English
Educational Codeforces Round 111 [Rated for Div. 2] Hello Codeforces! On [contest_time:1550] [contest:1550] 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.me/blog/entry/51208">blog post</a>. This round will be **rated for the participants with rating lower than 2100**. It will be held on extended ICPC rules. The penalty for each incorrect submission until the submission with a full solution is 10 minutes. After the end of the contest you will have 12 hours to hack any solution you want. You will have access to copy any solution and test it locally. You will be given **6 or 7 problems** and **2 hours** to solve them. The problems were invented and prepared by Adilbek [user:adedalic,2021-07-13] Dalabaev, Vladimir [user:vovuh,2021-07-13] Petrov, Ivan [user:BledDest,2021-07-13] Androsov, Mak...

Full text and comments »

  • Vote: I like it
  • +289
  • Vote: I do not like it

218.
By Errichto, 10 years ago, In English
Good Bye 2016 sponsored by Barcelona ACM-ICPC Camp Hello everybody! On December 30 at 14:05 UTC/17:05 MSK ([check your time zone here](http://timeanddate.com/worldclock/fixedtime.html?day=30&month=12&year=2016&hour=17&min=5&sec=0&p1=166)) Codeforces will host the New Year's contest Good Bye 2016. The contest is combined for both divisions, lasts 2.5 hours and contains 8 problems. Thanks to <a href="http://harbour.space/">Harbour.Space</a> and <a href="http://in.harbour.space/icpc/"> Barcelona ACM-ICPC Programming Bootcamp 2017</a> sponsoring the contest, winners can expect really cool prizes: - 5 best participants (not ACM ICPC veterans) will win free participation in Hello Barcelona programming bootcamp. - 30 best participants (not ACM ICPC veterans) will receive a 30% discount for participation in Hello Barcelona programming bootcamp. - 100 best participants will receive t-shrits by organizers and Codeforces. <center> <img src="http://codeforces.me/predownloaded/dd/0f/dd0fbc52ada73fb48011ce52adee739a248fa804.png"/> </...
. The registration is open up to **January 20th, 2017**.

Full text and comments »

Announcement of Good Bye 2016
  • Vote: I like it
  • +556
  • Vote: I do not like it

219.
By I_love_Hoang_Yen, history, 6 years ago, In English
2020 ICPC Vietnam Regional Contest on Kattis A month after the [Vietnamese National contest](https://codeforces.me/blog/entry/84587) have passed. This Friday (Dec 11, 2020), there will be the 2020 Vietnam Regional contest. We will also have an online mirror. Details of **Online Mirror**: - Time: [9am GMT+7](https://www.timeanddate.com/worldclock/fixedtime.html?msg=2020+ICPC+Vietnam+Regional+Contest+-+Online+Mirror&iso=20201211T02&p1=%3A&ah=5) - [Contest link](https://cantho20open.kattis.com/) Details of **Official Contest**: - Time: [8am GMT+7](https://www.timeanddate.com/worldclock/fixedtime.html?msg=2020+ICPC+Vietnam+Regional+Contest+-+Official+Contest&iso=20201211T01&p1=%3A&ah=5) - [Contest link](https://cantho20.kattis.com/) Problems prepared by: - [user:phamvanhanhgoldIOI2015,2020-11-15] - [user:chemthan,2020-11-15] - [user:I_love_Hoang_Yen,2020-11-15] - [user:I_love_tigersugar,2020-11-15] - [user:laoriu,2020-11-15] - [user:beo_chay_so,2020-11-15] - Prof. Do Duc Dong Contest difficulty won't b...
**UPD**: The problems are now on [Open Kattis](https://open.kattis.com/problem-sources/The%202020

Full text and comments »

  • Vote: I like it
  • +103
  • Vote: I do not like it

220.
By parveen1981, history, 5 years ago, In English
I compiled a list of almost all useful blogs ever published on Codeforces [update: till 09.06.2021] <h3 style="color:red">If there are any blogs that I have missed, please tell in the comment section. Thank you.</h3> # Mathematics Stuff - [Number Theory in Competitive Programming [Tutorial]](https://codeforces.me/blog/entry/46620) - [Number of points on Convex hull with lattice points](https://codeforces.me/blog/entry/62183) - [FFT, big modulos, precision errors.](https://codeforces.me/blog/entry/48465) - [Number of ways between two vertices](https://codeforces.me/blog/entry/19078) - [Mathematics For Competitive Programming](https://codeforces.me/blog/entry/76938) - [FFT and NTT](https://codeforces.me/blog/entry/19862) - [Burnside Lemma](https://codeforces.me/blog/entry/51272) - [Number of positive integral solutions of equation 1/x+1/y=1/n!](https://codeforces.me/blog/entry/76836) - [On burnside (again)](https://codeforces.me/blog/entry/64860) - [Simple but often unknown theorems/lemmas/formula? Do you know?](https://codeforces.me/blog/entry/55912) - [Probabili...
source: General tips'n'tricks](https://codeforces.me/blog/entry/79446) - [New data structures

Full text and comments »

  • Vote: I like it
  • +1500
  • Vote: I do not like it

221.
By prabowo, 2 years ago, In English
TOKI Open 2024 Hello Codeforces! We will host TOKI Open 2024. This is one of the tests to select the Indonesian team for [IOI 2024](https://www.ioi2024.eg/). Everyone is welcome to take part in this contest. The contest will be held in two days: - [Day 1](https://tlx.toki.id/contests/toki-open-2024-day-1/): [Saturday, 25 May 2024, 09:00 (UTC+7) — Sunday, 26 May 2024, 07:00 (UTC+7)](https://www.timeanddate.com/worldclock/fixedtime.html?msg=TOKI+Open+2024+Day+1&iso=20240525T09&p1=108&ah=22) - [Day 2](https://tlx.toki.id/contests/toki-open-2024-day-2/): [Sunday, 26 May 2024, 09:00 (UTC+7) — Monday, 27 May 2024, 07:00 (UTC+7)](https://www.timeanddate.com/worldclock/fixedtime.html?msg=TOKI+Open+2024+Day+2&iso=20240526T09&p1=108&ah=22) Some key details of the contest: - Duration: 5 hours - Style: IOI - Allowed language: C++17 - You can start at any time within the 22-hour window. All contest days are hosted on [TLX](https://tlx.toki.id/). Please register for an account if you do not ...
TOKI Open 2024, - [Day 1](https://tlx.toki.id/contests/toki-open-2024-day-1/): [Saturday, 25 May 2024, 09:00 (UTC+7, We hope that we can host TOKI Open again in the future!

Full text and comments »

  • Vote: I like it
  • +72
  • Vote: I do not like it

222.
By Marco_L_T, history, 4 months ago, In English
OpenFrontierCS Challenge: the AHC for Human-AI agent Collaboration on Open-Ended Tasks **Hello Codeforces!** Today, our team (me, [user:JoyeMang,2026-07-10], [user:Tohsaka_Sakura,2026-07-10], along with other amazing collaborators), with the support from Eigen Labs, are officially launching the **FrontierCS** AutoResearch challenge which is live at [http://openfrontiercs.com](http://openfrontiercs.com)! [Simply link your GitHub account and join!](http://openfrontiercs.com) Think of this as an **AtCoder Heuristic Contest where AI agents are fully allowed and actively encouraged and the duration is much longer for space to fully optimize.** **The Goal: Pushing the Ceiling of Human-Machine Collaboration** We want to measure the limits of human-AI collaboration on complex, ICPC challenge-style problems. While the open-source AI community is already heavily involved, we believe **human intelligence from competitive programmers is the missing key**. We want to see **how top algorithmic minds can guide, improve, and integrate their problem-solving wisdom into the...
OpenFrontierCS Challenge: the AHC for Human-AI agent Collaboration on Open -Ended Tasks, * **10 Frontier Problems:** A selected set of highly challenging ICPC Challenge styleopen-ended

Full text and comments »

  • Vote: I like it
  • +13
  • Vote: I do not like it

223.
By ace5, 17 months ago, In English
Very hard bug in a very simple code Take a look at this code: <spoiler summary="Code"> ~~~~~ #include <bits/stdc++.h> using namespace std; vector<int> k; int f() { k.push_back(3); return 3; } int main() { k.push_back(1); k[0] = f(); cout << k[0]; } ~~~~~ </spoiler> At first glance, it should output $3$ because that's what $f()$ returns, which is then assigned to $k_0$. But when executed, this code outputs $1$! This code is very short and everything seems clear, we're simply assinging $k_0$ to the return value of $f()$ which is $3$, and the push_back in $f()$ clearly doesn't affect the result... or does it? <h3>How an assingment operation really works</h3> It may seem obvious at first, we just copying one value to another, but let's see how compiler actually handles this operation. Consider this code. ([Source](https://en.cppreference.com/w/cpp/language/eval_order.html)) <spoiler summary="Code"> ~~~~~ #include <cstdio> int a() { return std::puts("a...
Consider this code. ([Source ](https://en.cppreference.com/w/cpp/language/eval_order.html))

Full text and comments »

  • Vote: I like it
  • +254
  • Vote: I do not like it

224.
By wuhudsm, history, 2 years ago, In English
Codeforces Round 960 (Div. 2) Editorial Thank you for participation and we hope you enjoy this round :) Additionally, we sincerely invite you to join the unofficial round of TheForces Community tomorrow. Compete alongside many high-rated participants and earn your own rating in a our own rating system([TheForces Rating System](https://theforces.netlify.app/ratings))! For more details, pls read https://codeforces.me/blog/entry/131733. #### [A &mdash; Submission Bait](https://codeforces.me/contest/1990/problem/A) <spoiler summary="hint1"> For Alice, what if choosing the maximum value doesn't work? </spoiler> <spoiler summary="hint2"> Consider parity. </spoiler> <spoiler summary="solution 1"> Case $1$: When all values appear an even number of times, Alice will lose. This is because no matter which number Alice chooses, Bob can mimic Alice's move. Case $2$: When at least one value appears an odd number of times, Alice will win. Alice only needs to choose the maximum value that appears an odd number ...
/** * Point-update Segment Tree * Source: kactl * Description: Iterative point-update segment

Full text and comments »

  • Vote: I like it
  • +92
  • Vote: I do not like it

225.
By jonathanirvings, history, 9 years ago, In English
Invitation to TOKI Open 2018 Hello! After we successfully organized [TOKI Open 2014](http://codeforces.me/blog/entry/12286) and [TOKI Open 2017](http://codeforces.me/blog/entry/51512), we are going to do the similar thing this year. We will open our current IOI Selection Contest to international participants. We call it **TOKI Open 2018**. TOKI stands for Tim Olimpiade Komputer Indonesia, or Indonesian Computing Olympiad Team in English. Objectives of us opening this contest include, but not limited to: - Measure the performance of our IOI trainee compared to other countries' IOI trainee. - Foster friendship between Indonesia and other IOI participating countries. - Test Indonesia's scientific committee capability in setting IOI-level problems. - Test Indonesia's technical committee capability in hosting IOI-level contests. The contest will have very similar format with IOI, as this contest will be used to select our Top 4 and train our Top 4 for IOI. We expect that the difficulty of the contest i...
Invitation to TOKI Open 2018, After we successfully organized [TOKI Open 2014](http://codeforces.me/blog/entry/12286) and [TOKI, The rules of TOKI Open 2018 are

Full text and comments »

  • Vote: I like it
  • +140
  • Vote: I do not like it

226.
By pashka, 6 years ago, In English
ITMO Algorithms Course Hello Codeforces! I teach a course on algorithms and data structures at ITMO University. During the last year I was streaming all my lectures on [Twitch](https://twitch.tv/pmavrin) and uploaded the videos on [Youtube](https://www.youtube.com/pavelmavrin). This year I want to try to do it in English. This is a four-semester course. The rough plan for the first semester: - Algorithms, complexity, asymptotics - Sorting algorithms - Binary heap - Binary search - Linked lists, Stack, Queue - Amortized analysis - Fibonacci Heap - Disjoint Set Union - Dynamic Programming - Hash Tables The lectures are open for everybody. If you want to attend, please fill out [this form](https://docs.google.com/forms/d/e/1FAIpQLSfHIhiwAUyKfnt92NluNj2tLnczp0oxu5szPS4S_PF3N7EUDA/viewform) to help me pick the optimal day and time. See you!
The lectures are open for everybody. If you want to attend, please fill out [this form](https

Full text and comments »

  • Vote: I like it
  • +879
  • Vote: I do not like it

227.
By -is-this-fft-, history, 4 years ago, In English
[Tutorial] Minimum cost (maximum) flow [Part 1: [Tutorial] My way of understanding Dinitz's ("Dinic's") algorithm](https://codeforces.me/blog/entry/104960) **Part 2: [Tutorial] Minimum cost (maximum) flow** [Part 3: [Tutorial] More about minimum cost flows: potentials and Dinitz](https://codeforces.me/blog/entry/105658) #### Introduction There is a section in our ICPC notebook from 2019 called "min cost dinic". This blog started as an attempt to dissect what was written in there and understand why it works. In time, I needed to refer to many general ideas about flow, so it developed into a more general treatment of (min-cost) flow problems and spawned an entire separate blog about maximum flow and Dinitz. Even after splitting the blog, this blog was still too long, so I split it yet again. This blog will deal with the basic ideas of minimum cost flow; there will be a part 3, where I will generalize to a Dinitz-like algorithm and also talk a bit about something called potentials. This blog is somewha...
**Minimum cost $b$-flow.** In this problem, there is no source or sink. Instead, for each vertex

Full text and comments »

  • Vote: I like it
  • +220
  • Vote: I do not like it

228.
By Monogon, history, 6 years ago, In English
[Tutorial] Voronoi Diagram and Delaunay Triangulation in O(n log n) with Fortune's Algorithm What's a Voronoi Diagram? ------------------ Given a set $S$ of $n$ points in the 2D plane, the Voronoi diagram is a partition of the plane into regions. The region associated with a point $p\in S$ contains precisely the points $q$ such that $q$ is closer to $p$ than any other point in $S$. In other words, a point $q$ belongs to the region of its nearest neighbor. <img src="https://upload.wikimedia.org/wikipedia/commons/thumb/5/54/Euclidean_Voronoi_diagram.svg/1024px-Euclidean_Voronoi_diagram.svg.png" width="300px" height="auto"/> The Voronoi diagram can be represented by the planar graph of boundaries between regions. A vertex in this graph is where three or more segments meet (or a point at infinity), and an edge is a segment connecting two of these vertices. The way the regions were defined, we see that a segment contains the points equidistant to two points in $S$, so it is part of their perpendicular bisector. Similarly, a Voronoi vertex is equidistant to three or more v...

Full text and comments »

  • Vote: I like it
  • +499
  • Vote: I do not like it

229.
By Zlobober, 9 years ago, translation, In English
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.me/blog/entry/21185), [342](http://codeforces.me/blog/entry/23309), [345](http://codeforces.me/blog/entry/43615), [376](http://codeforces.me/blog/entry/47769), [401](http://codeforces.me/blog/entry/50613), [433](http://codeforces.me/blog/entry/54350), [441](http://codeforces.me/blog/entry/55201), [466](http://codeforces.me/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 ...
Codeforces Round #469 (based on Moscow Open Olympiad), Open Olympiad consists of the most interesting and hard problems that are proposed my a wide

Full text and comments »

  • Vote: I like it
  • +236
  • Vote: I do not like it

230.
By Radewoosh, 11 years ago, In English
Codeforces Round #304 (Div.2) editorial A. Soldier and Bananas ---------------------- We can easily calculate the sum of money that we need to buy all the bananas that we want, let's name it x. If n >  = x the answer is 0, because we don't need to borrow anything. Otherwise the answer is x - n. B. Soldier and Badges --------------------- Let's count the number of badges with coolness factor 1, 2 and so on. Then, let's look at the number of badges with value equal to 1. If it's greater than 1, we have to increase a value of every of them except for one. Then, we look at number of badges with value 2, 3 and so on up to 2n - 2 (because maximum value of badge which we can achieve is 2n - 1). It is easy to see that this is the correct solution. We can implement it in O(n), but solutions that work in complexity O(n^2) also passed. C. Soldier and Cards -------------------- It's easy to count who wins and after how many "fights", but it's harder to say, that game won't end. How to do it? Firstly le...
Make a source.

Full text and comments »

  • Vote: I like it
  • +58
  • Vote: I do not like it

231.
By awoo, history, 5 years ago, translation, In English
Educational Codeforces Round 110 [Rated for Div. 2] Hello Codeforces! On [contest_time:1535] [contest:1535] 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.me/blog/entry/51208">blog post</a>. This round will be **rated for the participants with rating lower than 2100**. It will be held on extended ICPC rules. The penalty for each incorrect submission until the submission with a full solution is 10 minutes. After the end of the contest you will have 12 hours to hack any solution you want. You will have access to copy any solution and test it locally. You will be given **6 or 7 problems** and **2 hours** to solve them. The problems were invented and prepared by Roman [user:Roms,2021-06-03] Glazov, Adilbek [user:adedalic,2021-06-03] Dalabaev, Vladimir [user:vovuh,2021-06-03] Petrov, Ivan [us...

Full text and comments »

  • Vote: I like it
  • +350
  • Vote: I do not like it

232.
By codetiger927, history, 4 years ago, In English
Lexington Informatics Tournament 2022 (Registration Open!) **Participants can join our Discord server [here](https://discord.gg/k6yzFdZ)** The [LexMACS](https://lhsmathcs.org/) (Lexington Mathematical CS) club is proud to announce our third annual **Lexington Informatics Tournament 2022**! The contest window lasts from [July 21 — July 25 EDT](https://www.timeanddate.com/worldclock/fixedtime.html?msg=Lexington+Informatics+Tournament+%28LIT%29+2022&iso=20220721T16&p1=263), and participants can begin their **3 hours** window at any time. If you are interested, please visit our website at [https://lit.lhsmathcs.org/](https://lit.lhsmathcs.org/). Once you register, you can see all the past problems on the contest page. Some of our problem-setters include [user:codetiger927,2022-07-11], [user:eggag32,2022-07-11], [user:superj6,2022-07-11], and [user:eyangch,2022-07-11]. Special thanks to testers [user:DreamingLeaf,2022-07-11], [user:Tlatoani,2022-07-15], [user:fishy15,2022-07-19], [user:fivefourthreeone,2022-07-19] as well! LIT consists of tw...
Lexington Informatics Tournament 2022 (Registration Open!), **Update:** Open ceremony starting soon at [https://www.youtube.com/watch?v=5QCkheqOp3s&ab_channel

Full text and comments »

  • Vote: I like it
  • +198
  • Vote: I do not like it

233.
By prabowo, history, 5 years ago, In English
Invitation to TOKI KSN Open Contest 2021 Hello Codeforces community, We are excited to invite you to **TOKI KSN Open Contest 2021** — an online mirror contest for the Indonesia national olympiad in informatics. This national olympiad is one of the stages required for our students to qualify to represent Indonesia in the International Olympiad in Informatics (IOI). You may have seen our past open olympiads ([2015](https://codeforces.me/blog/entry/17924), [2016](https://codeforces.me/blog/entry/44892), [2017](https://codeforces.me/blog/entry/53037), [2018](https://codeforces.me/blog/entry/60263), [2019](https://codeforces.me/blog/entry/67967), [2020](https://codeforces.me/blog/entry/83514)) and you can check our past problems [here](https://tlx.toki.id/problems/problemsets?archive=osn). The contest is similar to IOI: 2 competition days (+ 1 trial session), each consisting of 3 IOI-style (partial, subtasks) problems to be solved in 5 hours. The schedule is as follows: * Day 0: [7 November 2021 09:00 — 8 November 2...
Invitation to TOKI KSN Open Contest 2021, The result of the open contest can be found on [our website](https://ksn2021.toki.id/open-results).

Full text and comments »

  • Vote: I like it
  • +133
  • Vote: I do not like it

234.
By rama_pang, history, 4 years ago, In English
Invitation to TOKI Indonesian NOI Open Contest 2022 Hello Codeforces community, We are excited to invite you to **TOKI Indonesian NOI Open Contest 2022** — an online mirror contest for the Indonesian National Olympiad in Informatics. This national olympiad is one of the stages required for our students to qualify to represent Indonesia in the International Olympiad in Informatics (IOI). You may have seen our past open olympiads ([2015](https://codeforces.me/blog/entry/17924), [2016](https://codeforces.me/blog/entry/44892), [2017](https://codeforces.me/blog/entry/53037), [2018](https://codeforces.me/blog/entry/60263), [2019](https://codeforces.me/blog/entry/67967), [2020](https://codeforces.me/blog/entry/83514), [2021](https://codeforces.me/blog/entry/96689)), and you can check our past problems [here](https://tlx.toki.id/problems/problemsets?archive=osn). The contest is similar to IOI: 2 competition days (+ 1 trial session), each consisting of 3 IOI-style (partial, subtasks) problems to be solved in 5 hours. The schedule is...
Invitation to TOKI Indonesian NOI Open Contest 2022, Congratulations to [user:errorgorn,2022-10-19] for winning the contest! The result of theopen

Full text and comments »

  • Vote: I like it
  • +126
  • Vote: I do not like it

235.
By nitor, history, 5 years ago, In English
Presenting Tourist Facts Hello everyone! I am excited to show a project I've been working on these days — It's called "[**Tourist Facts**](https://touristfacts.dikson.xyz/)". You can access the website at [touristfacts.dikson.xyz](https://touristfacts.dikson.xyz/). ![ ](https://i.imgur.com/aME4nD2.png) This is a compilation of facts _(some haters would call them "absurd hyperbolic claims")_ about [user:tourist,2021-10-28], inspired in things like [Chuck Norris facts](https://en.wikipedia.org/wiki/Chuck_Norris_facts). Suggesting new facts is _really simple!_ &mdash; just login to your GitHub account, [submit an issue (by clicking here)](https://github.com/diksown/touristfacts/issues/new?assignees=&labels=fact+suggestion&template=fact-suggestion.md&title=Fact+suggestion), type the facts you want to add (one per line) and hit "submit new issue". &mdash; I'll review the facts, and if they are funny, original and respectful, I'll tag the issue with a "accepted" label, all lines will be automatically ...
This project is open source <3 — For more info, check it's [GitHub repository](https

Full text and comments »

  • Vote: I like it
  • +489
  • Vote: I do not like it

236.
By Swistakk, history, 8 years ago, In English
Ultimate guide to TopCoder plugins Hi, I wanted to present to you guide on how you should set up TopCoder Arena in order to make competing in TC much more pleasant experience. Or at least guide how to do the same thing as I did which seem very comfortable to me compared to this big pain of competing in bare default Arena. In case you want to grab easy upvotes please leave here some joke about how I am jealous about ~Radewoosh,2018-08-16 getting insane boost in his contribution by writing his blogs, but the real reason is that I screwed my setup recently and needed to go through this painful and magical setup once again and it seems this information is very nontrivial and not available publicly in a known place (which I believe is one of reasons TopCoder is losing its popularity, but I hope thanks to this post I can give slight boost to it by settling up Arena problems once and for all for many people), so I wanted to share it with others. I want to express my sincere thanks to [user:tomasz.kociumaka,2018-08-16] for guid...
1) When I open a problem statement they create a new file corresponding to this task in a

Full text and comments »

  • Vote: I like it
  • +302
  • Vote: I do not like it

237.
By Dormi, 5 years ago, In English
Codeforces LATOKEN Round 1 (Div. 1 + Div. 2) Hello, Codeforces! Welcome to the [contest:1534] supported by LATOKEN, that will start on [contest_time:1534]. It will be a combined rated round for both divisions (and div 3). **Please, note the unusual start time.** All problems were created by [user:Aaeria,2021-06-09], [user:crackersamdjam,2021-06-12], [user:Dormi,2021-06-09], [user:Ninjaclasher,2021-06-09], and [user:Plasmatic,2021-06-09]. We would like to thank: - Valentin Preobrazhenskiy from LATOKEN supporting the round. - [user:300iq,2021-06-10] and [user:kan,2021-06-10] for coordinating the round and answering our relentless questions. - [user:arvindr9,2021-06-09], [user:delmos,2021-06-09], [user:duality,2021-06-09], [user:growup974,2021-06-09], [user:m371,2021-06-09], [user:purplecrayon,2021-06-09], [user:rkm62,2021-06-09], [user:socho,2021-06-09], [user:wleung_bvg,2021-06-09], and [user:zeyu,2021-06-09] for their invaluable advice and suggestions. - [user:MikeMirzayanov,2021-06-09] for great systems Codeforces...
blockchain based financial systems will open exciting opportunities, because crypto is fully global and

Full text and comments »

  • Vote: I like it
  • +638
  • Vote: I do not like it

238.
By hloya_ygrt, 7 years ago, translation, In English
X BSUIR Open Programming Championship <div style="text-align: center; margin-bottom: 10px;"> <img src="/predownloaded/8e/c4/8ec47dc8ee73d992e81bb7974a1dde9590a4490f.png" /> </div> The **X BSUIR Open Programming Championship** will be held from March 21 till May 7, 2020 (Minsk, Belarus). Semifinal is over, upsolving is open and standings are unfreezed. Thanks to the problemsetters: [user:aropan,2016-11-08], [user:teleport,2016-08-06], [user:wilcot,2020-04-08], [user:ShavelV,2020-04-08], [user:rui-de,2020-04-08], [user:Vladik,2020-04-08], [user:netman,2016-11-08]. Results here: [students](https://contest.yandex.ru/contest/17437/standings?lang=en) и [school](https://contest.yandex.ru/contest/17438/standings?lang=en). **UPD3:** Registration deadline comes in **30 hours**. **UPD:** [Telegram channel](https://t.me/bsuir_open_x_news). There's a link there to a chat, where you can talk to other participants and team up. **UPD2:** With respect to the situation in the world, organizing committee decided to mak...
X BSUIR Open Programming Championship

Full text and comments »

  • Vote: I like it
  • +208
  • Vote: I do not like it

239.
By ToxicPie9, 7 months ago, In English
April Fools Day Contest 2026 Editorial Thanks for participating! ### [2214A &mdash; Odd One Out](https://codeforces.me/contest/2214/problem/A) Idea: [user:flamestorm,2026-04-01] <spoiler summary="Solution"> You just need to output the arrow that only appears once. That arrow is **C2**. </spoiler> <spoiler summary="Code (Python)"> ~~~~~ print("C2") ~~~~~ </spoiler> <spoiler summary="Feedback"> - I liked it! </spoiler> ### [2214B &mdash; Are You Smiling?](https://codeforces.me/contest/2214/problem/B) Idea: [user:prvocislo,2026-04-01] <spoiler summary="Solution"> One unusual thing about the statement is the presence of a emoji. More precisely, a smiling, emoji. Okay, let's try to print a smiling emoji. However, the output should be a string of characters and numbers, so we cannot do it directly. There's one more suspicious thing in the statement &mdash; the $U+?=HAPPY$ equation. If we should print ?, what is the meaning of U? U+ often indicates that an unicod...
This problem's source code can be found [here](https://github.com/ToxicPie/are-you-a-robot-3)

Full text and comments »

  • Vote: I like it
  • +266
  • Vote: I do not like it

240.
By -XraY-, history, 16 months ago, In English
Order Capital Intro <img alt="Order Capital" src="/predownloaded/00/3e/003eef1043e9506ad4620583c5be192631830899.png" style="float:right;height: 200px; margin: 10px; max-width:40%;"/> Hello everyone! I invite you to take part in [contest:2122]. My name is Igor Pyshkin. Throughout my academic career, I participated in a lot of programming and math competitions: I am the 2016 ACM ICPC World Champion and competed in the onsite finals of the Facebook Hacker Cup, Google Code Jam, and TopCoder Open. After completing my degree, I transitioned into a new field — high-frequency trading (HFT). Four years ago, I founded my own HFT fund — [Order Capital](https://ordercapital.com/). Since then together with my colleagues I have been working really hard to reach the highest levels of the HFT industry. Launching this contest on Codeforces is quite special to me, as it is our first contest on the platform as a company. I would like to thank the Codeforces team and everyone involved in the round preparation...
Facebook Hacker Cup, Google Code Jam, and TopCoder Open. After completing my degree, I transitioned

Full text and comments »

  • Vote: I like it
  • +438
  • Vote: I do not like it

241.
By Xiaohuba, 12 months ago, In English
Codeforces Global Round 30 Hello, Codeforces! We are pleased to announce the resumption of the Global Rounds. Thanks to XTX Markets for supporting the initiative! In 2025, we will hold 3 such rounds. The series results will take into account the best 2 participations out of 3. On [contest_time:2164] we will host [contest:2164]. **<img src="/predownloaded/2e/e2/2ee2f0f95f05aae6ca6f47812dae2dc2aabf277b.png" style="width: 200.0px;float: right;margin: 0 1.0em 1.0em 1.0em;max-width: 100.0%;max-height: 100.0%;">** Codeforces Global Round 30 marks the second round in the 2025 series of Codeforces Global Rounds. These rounds are open and rated for everyone. The prizes for this round are as follows: - The top 30 participants will receive a t-shirt. - 20 t-shirts will be randomly distributed among participants ranked between 31 and 500, inclusive. The prizes for the 3-round series in 2025: - In each round, the top-100 participants get points according to the [table](https://pastebin.com/NMzrRc...
. These rounds are open and rated for everyone.

Full text and comments »

  • Vote: I like it
  • +405
  • Vote: I do not like it

242.
By Pyqe, 2 years ago, In English
Invitation to TOKI Indonesian NOI Open Contest 2024 Hello Codeforces community, We are excited to invite you to **TOKI Indonesian NOI Open Contest 2024** — an online mirror contest for the Indonesian National Olympiad in Informatics 2024. This national olympiad is one of the stages required for our students to qualify to represent Indonesia in the International Olympiad in Informatics (IOI) 2025. You may have seen our past open olympiads ([2015](https://codeforces.me/blog/entry/17924), [2016](https://codeforces.me/blog/entry/44892), [2017](https://codeforces.me/blog/entry/53037), [2018](https://codeforces.me/blog/entry/60263), [2019](https://codeforces.me/blog/entry/67967), [2020](https://codeforces.me/blog/entry/83514), [2021](https://codeforces.me/blog/entry/96689), [2022](https://codeforces.me/blog/entry/107378), [2023](https://codeforces.me/blog/entry/119797)), and you can check our past problems [here](https://tlx.toki.id/problems/problemsets?archive=osn). The contest is **similar to IOI**: 2 contest days (+ 1 trial ...
Invitation to TOKI Indonesian NOI Open Contest 2024, **UPD**: The open contest windows are over!

Full text and comments »

  • Vote: I like it
  • +56
  • Vote: I do not like it