MikeMirzayanov's blog

By MikeMirzayanov, 10 years ago, translation, In English

Good afternoon!

I've decided to share my thoughts on the round 382.

Of course, it turned upset not only to me, but also to the round coordinator GlebsHP.

In this round the main negative feedback were caused by two problems: 735D - Taxes and 735C - Tennis Championship.

Regarding 735D - Taxes. I do not share the criticism to this problem. In fact, to solve it would be nice to be familiar with Goldbach's Conjecture and better with Prime Number Theorem. These facts are medium-popular in the world of programming contests. Familiarity with them is useful, gives useful insight into primes. It is important: in this problem it was necessary to perform a simple, but nevertheless, additional step to find solution. It seems to me that it's okay to use problems that have a reduction to some popular and semi-popular topics. Otherwise, it is thrown away a huge number problems.

As a summary for this problem. I agree that the problem 735D - Taxes is not an example of the best problem. But it has a right to exist as one of the problems in a round. It can not take a role of any argument in favor of unrated round. I personally, would not include it in my contest. But the fact of the use of the Goldbach's conjecture (and more prime number theorem) is not a reason for me to convict and forbid a problem.

The situation with the problem 735C - Tennis Championship is much more complicated. It is necessary not to mix the two fundamentally different reasons for occurrence of same problems:

  • Problems can be matched randomly, inadvertently. Of course, the coordinator and testers always have a critical look on the problem. At the stage of the contest preparation they immediately react if a problem is familiar to somebody. It is important to understand, that huge number of problems have been invented over the years of existence of sports programming. It is physically impossible to be familiar even with a large part of them. No matter how experienced the jury, sometimes, coincidences happen. Note that if the round is not a stage of a championship and its results do not affect prizes the main reasons for participation in it should be self-development and a desire to get a fan from the competition. None of these goals encourage search in Google.

  • Deliberate coincidence or reuse of problems, it is a different story. And here it is what happened. This situation is totally unacceptable (educational rounds do not count), it is necessary to fight with it and to respond rapidly to incidents.

As soon as I examined about the incident, immediately called by phone the writer and discussed (and denounced) the situation. I explained the inadmissibility of such cases and their implications. I think Albert made the correct conclusions and will be accurate in future. Unfortunately, I was informed about incident only after the ratings been updated.

Taking into account large number of participants who didn't notice the issue, who solved problems completely independently, who were happy of upset by their rating changes, shared their results in social networks it does not seem respectful to do to them unrated. I share the view that it would be better not to be so, but history has already taken place. Note that if I learned the situation during the round or immediately after, the outcome might be different. I think it's a good idea to report suspected cases through questions to give a chance the coordinator or me react quickly.

As a conclusion, I do not propose to raise the tragedy, coordinators do not despair. The writers, of course, need to understand the responsibility and importance of taking on the role. Thousands of participants come to solve your problems and, of course, expect something interesting and new.

I urge the community not to forget about respect for the work of authors: to prepare the contest is a big and difficult task. The author takes on a difficult role and if a round took place, so the hard way from the idea to the final implementation has done. Please, be grateful for it, say the authors, coordinators and testers, thank you!

Whatever effort the Codeforces team makes, we can not do rounds without the writers. Therefore, we look forward to your problems. Hope to see good and bright rounds here!

Thank you for attention,
MikeMirzayanov

Full text and comments »

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

By MikeMirzayanov, history, 10 years ago, translation, In English

Hello, my dear lovers of algorithms and data structures.

Codeforces Round 380 will start on November 20 (Sunday), 09:05 (UTC). It will be based on Technocup 2017 Elimination Round 2. So, if you are a Russian-speaking high-school student, please take part in the Technocup 2017.

Many thanks to KAN, GlebsHP, fcspartakm, Levshunovma. Hope to extend the list soon because of testers. Also some problem ideas are mine.

I hope you will like problems. It will be 6 problems in each division.

Good luck and bugless code

Scoring:

  • TK Elim 2 and Div 2: 500-1000-1750-1750-2000-2500
  • Div 1: 750-750-1000-1500-2000-2500

UPD 1: Here are our winners!

Top-5 in the Technocup stage:

  1. sslotin
  2. Arthur
  3. hloya_ygrt
  4. asokol
  5. Denisson

Top-5 in Div.1:

  1. riadwaw
  2. MrDindows
  3. Belonogov
  4. dreamoon_love_AA
  5. LHiC

Top-5 in Div.2:

  1. Ralsei
  2. NotDeep94
  3. ecvlco397
  4. kongroo
  5. meeeep

Full text and comments »

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

By MikeMirzayanov, history, 10 years ago, translation, In English

Welcome to 2016-2017 CT S03E09: Codeforces Trainings Season 3 Episode 9. The training duration is 5 hours. It is opened for teams as well as for individual participants. After the end you may use the practice mode to complete problem solving. Also it will be available as a virtual contest for whose of you who can't take part today. Please, do not cheat. Only fair play!

Visit Codeforces::Gym to find the contest and register.

We are planning to start on November 9, 2016 13:10 (UTC).

It is possible that the problems will be too easy for some participants, it is possible that we will add some problems.

Good luck!

Full text and comments »

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

By MikeMirzayanov, history, 10 years ago, translation, In English

Hello everybody!

The contest is over, and I've found that there is no post about the contest. I'm waiting for unfreeze of http://opentrains.snarknews.info/~ejudge/res/res10355 Who knows the expected time?

Let's discuss problems here.

Also it is interesting how good was the onsite in Novosibirsk. What impressions?

Full text and comments »

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

By MikeMirzayanov, history, 10 years ago, translation, In English

Welcome to 2016-2017 CT S03E08: Codeforces Trainings Season 3 Episode 8 - 2005-2006 ACM-ICPC, Tokyo Regional Contest + 2010 Google Code Jam Qualification Round (CGJ 10, Q). The training duration is 5 hours. It is opened for teams as well as for individual participants. After the end you may use the practice mode to complete problem solving. Also it will be available as a virtual contest for whose of you who can't take part today. Please, do not cheat. Only fair play!

Visit Codeforces::Gym to find the contest and register.

We are planning to start on November 2, 2016 13:10 (UTC).

It is possible that the problems will be too easy for some participants, it is possible that we will add some problems.

Good luck!


Full text and comments »

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

By MikeMirzayanov, history, 10 years ago, translation, In English

Welcome to 2016-2017 CT S03E07: Codeforces Trainings Season 3 Episode 7 - HackerEarth Problems Compilation. The training duration is 5 hours. It is opened for teams as well as for individual participants. After the end you may use the practice mode to complete problem solving. Also it will be available as a virtual contest for whose of you who can't take part today. Please, do not cheat. Only fair play!

Many thanks to Errichto for the preparation of the training. He has saved me!

Visit Codeforces::Gym to find the contest and register.

We are planning to start on October, 26, 2016 13:10 (UTC).

It is possible that the problems will be too easy for some participants, it is possible that we will add some problems.

Good luck!

UPD: The training is over. Many thank to HackerEarth for problems! Undoubtedly Errichto is my hero of the day — he've prepared the training! Special thanks to the problem writers.

The editorial is in the comment http://codeforces.me/blog/entry/47985?#comment-322692


Full text and comments »

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

By MikeMirzayanov, history, 10 years ago, translation, In English

Today 2016-2017 ACM-ICPC, NEERC, Southern Subregional Contest will be held. On behalf of jury and hosts I wish teams to make happy their coaches!

You can watch the results by the link https://contest.sgu.ru/monitor/1.

And on Sunday (October, 23) on 08:00 (UTC) we will host unofficial online mirror. Interesting problems are waiting for you. Judges tried to prepare problems of wide difficulty range: for newcomers and for expirienced teams. This will be a team/personal contest on Codeforces, with teams consisting of up to three people or individual participants. The contest will not affect Codeforces ratings.

For sure, it will be unrated contest. We recommend you to take part in teams. I think, the contest will be moved to Gym later.

Good luck!

MikeMirzayanov, head of judges.

Full text and comments »

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

By MikeMirzayanov, history, 10 years ago, translation, In English

Hello, my dear Codeforcers!

Technocup is the olympiad for Russian-speaking highschool children. The winners will get significant benefits to enroll at Russian universities.

But it become open for everyone! Even if you are not a Russian-speaking highschool children, you can register for unofficial (out-of-olympiad) participation. The problems will be translated to English.

The contest starts on October 15, 09:05 (UTC). It will contain 6 problem to solve.

It will be rated round for:

  • official Technocup participants
  • unofficial participants from Div. 2

The contest will be hosted according Codeforcers rules.

UPD 1: The scoring is 1000-1000-1500-1500-2500-3000.

Full text and comments »

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

By MikeMirzayanov, history, 10 years ago, In English

Welcome to 2016-2017 CT S03E06: Codeforces Trainings Season 3 Episode 6. The training duration is 5 hours. It is opened for teams as well as for individual participants. After the end you may use the practice mode to complete problem solving. Also it will be available as a virtual contest for whose of you who can't take part today. Please, do not cheat. Only fair play!

Visit Codeforces::Gym to find the contest and register.

We are planning to start on October, 12, 2016 13:10 (UTC).

It is possible that the problems will be too easy for some participants, it is possible that we will add some problems.

Good luck!







Full text and comments »

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

By MikeMirzayanov, history, 10 years ago, translation, In English

Welcome to 2016-2017 CT S03E05: Codeforces Trainings Season 3 Episode 5 (2016 Stanford Local Programming Contest, Extended). The training duration is 4.30 hours. It is opened for teams as well as for individual participants. After the end you may use the practice mode to complete problem solving. Also it will be available as a virtual contest for whose of you who can't take part today. Please, do not cheat. Only fair play!

Visit Codeforces::Gym to find the contest and register.

We are planning to start on October, 5, 2016 13:10 (UTC).

It is possible that the problems will be too easy for some participants, it is possible that we will add some problems.

Good luck!

Full text and comments »

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

By MikeMirzayanov, history, 10 years ago, translation, In English

Welcome to 2016-2017 CT S03E04: Codeforces Trainings Season 3 Episode 4. The training duration is 4.30 hours. It is opened for teams as well as for individual participants. After the end you may use the practice mode to complete problem solving. Also it will be available as a virtual contest for whose of you who can't take part today. Please, do not cheat. Only fair play!

Visit Codeforces::Gym to find the contest and register.

We are planning to start on September, 28, 2016 13:10 (UTC).

It is possible that the problems will be too easy for some participants, it is possible that we will add some problems.

Good luck!

Full text and comments »

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

By MikeMirzayanov, history, 10 years ago, In English

Welcome to 2016-2017 CT S03E03: Codeforces Trainings Season 3 Episode 3 - 2007-2008 ACM-ICPC, Central European Regional Contest 2007 (CERC 07). The training duration is 4.30 hours. It is opened for teams as well as for individual participants. After the end you may use the practice mode to complete problem solving. Also it will be available as a virtual contest for whose of you who can't take part today. Please, do not cheat. Only fair play!

We are planning to start on September, 21, 2016 13:10 (UTC).

It is possible that the problems will be too easy for some participants, it is possible that we will add some problems.

Good luck!

Full text and comments »

Tags gym
  • Vote: I like it
  • +104
  • Vote: I do not like it

By MikeMirzayanov, history, 10 years ago, translation, In English

Welcome to 2016-2017 CT S03E02: Codeforces Trainings Season 3 Episode 2 - 2004-2005 Open Cup, Volga Grand Prix. The training duration is 4.30 hours. It is opened for teams as well as for individual participants. After the end you may use the practice mode to complete problem solving. Also it will be availible as a virtual contest for whose of you who can't take part today. Please, do not cheat. Only fair play!

We are planning to start on September, 14, 2016 13:10 (UTC).

It is possible that the problems will be too easy for some participants, it is possible that we will add some problems.

Good luck!

Full text and comments »

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

By MikeMirzayanov, history, 10 years ago, In English

Welcome to 2016-2017 CT S03E01: Codeforces Trainings Season 3 Episode 1 - 2010 Benelux Algorithm Programming Contest (BAPC 10). The training duration is 4.30 hours. It is opened for teams as well as for individual participants. After the end you may use the practice mode to complete problem solving. Also it will be availible as a virtual contest for whose of you who can't take part today. Please, do not cheat. Only fair play!

It is possible that the problems will be too easy for some participants, it is possible that we will add some problems.

Good luck!

Full text and comments »

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

By MikeMirzayanov, history, 10 years ago, translation, In English

The new season of a collegiate team championship ACM-ICPC is about to start. For example, the registration for the Southern (Saratov) Subregional Contest is already running. I am sure that many participants of the Codeforces rounds will take part in ACM-ICPC this year.

We are launching a series of weekly practice trainings on Codeforces. Naturally, they will be held within Codeforces::Gym. Feel free to participate!

The practice starts on Wednesdays at about 13:10 PM (UTC), which is 16:10 Moscow Time. Expected duration is 4-5 hours. We are going to practice using the problems of different contests of the past years. All you need is common sense and observing these simple rules:

  • We will not publish the problem source before the practice starts. We want you to solve the problems on your own in a fair competition. If you use somebody else’s code or cheat in any other way, you will be disqualified. If you don’t want to solve on your own, that’s fine, you don’t have to. But spoiling the practice for others is unacceptable.
  • Do not discuss the problems till the practice ends.
  • We will rarely answer the questions about problems. If you’ve found some obvious bug, please let me know. We will fix the bug and send everybody the note about the fix.
  • If you have a coach account (and you do not participate in the practice), we will be grateful for your help.
  • Please register for the practice with the people from your team who actually participates in it.
  • From time to time, I am going to ask some of the jury of the past contests or coaches from other higher educational institutions to help with preparing or share materials — your understanding and help will be greatly appreciated!
  • if you solved the contest problems before just switch to another training or inform us via problem questions form, we will move you to out-of-competition role.

The first contest 2016-2017 CT S03E01: Codeforces Trainings Season 3 Episode 1 - 2010 Benelux Algorithm Programming Contest (BAPC 10) takes place on September, 7, at about 13:10 (UTC).

Full text and comments »

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

By MikeMirzayanov, history, 10 years ago, translation, In English

I am glad to inform you that C++14 has been added to the list of supported languages ​​on Codeforces. The choice fell on the compiler MinGW-w64, version of GCC 6.2.0 (will be updated on new releases). If you have Windows, you can easlily install it using PBOX with one command pbox install mingw-w64.

Besides trendy features of C++14 (not sure there's a lot to the contests), there are some advantages:

  • this compiler is faster than mingw-tdm 5.1.0 on cin/cout — for example, reverse a sequence of 106 integers from 1 to 106 runs 1.5 seconds instead of 2.5 (0.3 vs. 1 if you use std :: ios :: sync_with_stdio (false))
  • works correctly to print a double with the both specifiers %f and %lf (you should read using %lf)
  • works correctly to read-write long double with the specifier %Lf
  • works correctly to read-write long long both with %lld and %I64d

It seems that lately we remove support of MinGW C++/C++11 (especially since it is difficult to upgrade them to GCC 6 due to backward compatibility issues). Of course, after a while C++14 will appear on Polygon.

Full text and comments »

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

By MikeMirzayanov, history, 10 years ago, translation, In English

The language of the round is Kotlin. Kotlin is a statically-typed programming language that runs on the Java Virtual Machine and also can be compiled to JavaScript source code. Its primary development is from a team of JetBrains programmers based in Saint Petersburg, Russia (the name comes from the Kotlin Island, near St. Petersburg).

Here is an example of the simplest program on Kotlin to print sum of two numbers:

fun main(args: Array<String>) {
    val (x, y) = readLine()!!.split(' ').map(String::toInt)
    println(x + y)
}

Here are some links to help you with Kotlin:

You can download standalone compiler (version 1.0.1) by the link http://s.codeforces.com/files/kotlin-compiler-1.0.1.zip Also you need JRE (virtual Java machine), you can find it by the link http://www.oracle.com/technetwork/java/javase/downloads/jre8-downloads-2133155.html

The password from the archives with IDEA (IDE supporting Kotlin out of the box): c8bf9dd9b91ad9ff Links to IDEA are below or you can download it from the official website

Good luck!

====

UPD: You can predownload development pack (sorry, 300MB). In fact, you can take part without it — the Custom Invocation tab will be available during the contest. Also we will publish more compact tools 30 minutes before the start.

OS
Linux http://s.codeforces.com/files/683-linux.7z
Windows http://s.codeforces.com/files/683-windows.7z
Mac OS http://s.codeforces.com/files/683-macos.7z

All archives are encrypted. The password will be announced 30 minutes before the contest.

========

Surprise Language Round #8 will start on June 16, 16:00 (UTC). It will be unusual entertaining contest. Solutions on the only programming language will be allowed.

Thus, it is expected that during the round, participants can get acquainted with the language and solve a few simple problems. The language will be announced 30 minutes before the start of the round. At the same time (or earlier but encrypted archives) we will publish the archives with the tools to write programs in this language.

I am pleased to announce that the top 20 participants will receive an exclusive t-shirt, and another 10 random participants among those who solved at least three problems will receive an exclusive t-shirt too.

The rules of the contest are as follows:

  • The contest is unrated for everybody.
  • The round uses ACM ICPC rules: the standing is defined by the number of solved problems, ties are resolved based on penalty time. Initially the penalty is 0, and for each solved problem it is increased by submission time (since the start of the contest) + 20 minutes for each failed submission. The solution is considered to be correct if it passes all tests from a predefined test set; you know whether the solution is right immediately after sending it. There are no hacks.
  • The round will have 8-10 problems, sorted by estimated complexity, and you have 2 hours to solve it.
  • Solutions are accepted only in one language, which will be announced in 30 minutes before the contest.
  • Please reread this post at the beginning of the contest: we will announce the language and add instructions to install the compiler (the contest interface will provide an option to run your solutions online as well) and links to useful manuals. Other than that, learning the language is up to the competitor. You can use any resources to solve the problems (as long as you remember that this is an individual competition); you don't have to limit yourself to the manuals provided in the post.

Good luck!

Full text and comments »

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

By MikeMirzayanov, 10 years ago, translation, In English

Sometimes you can meet interactive problems on programming contests (including Codeforces).

In problems of this type, the input data given to your program may be not predetermined but is built specifically for your solution. Jury writes a special program — interactor, such that its output is tranferred to the input of your solution, and the output of your program is sent to interactor’s input. In the other words, your solution and the interactor exchange the data and my decide what to print based on the "history of communication".

When you write the solution for the interactive problem it is important to keep in mind that if you output some data it is possible that this data is first placed to some internal buffer and may be not directly transferred to the interactor. In order to avoid such situation you have to use special flush operation each time you output some data.

Full text and comments »

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

By MikeMirzayanov, 10 years ago, translation, In English

Today, June 2, 2016 year, there was a technical failure, which I will remember for a long time. Several factors led to a serious malfunction of the Polygon system.

The fact that in the middle of May Polygon was transferred to servers located in Mail.Ru data centers. To transfer with almost no downtime (Polygon has a lot of data, about a terabyte) lsyncd utility has been used, which quickly pushed the file changes from the old server to the new one.

Today there was a reboot of the old server, which forced the unplanned start of lsyncd daemon. As a result it did the synchronization of data from the old server to the new again. So, data stored in the file system have been rolled back to the transfer time (May 13). The most unlucky fast that, unlike the old server where the backups system was set up well and reliable, on the new server, I quickly managed to set up only replication using the same lsyncd, which does not help in the incident of files deletion (as it forces the removals on the replica). Obviously, RAID-1 disks didn't save the data.

As a result, all file changes in the Polygon system made in three-week period were lost. Some information (statements, etc) is stored in the database, so accessible.

This night I urgently implemented the special link "Scraps" to download the archive with the available data. If a problem has been used in the Codeforces infrastructure, the packages remain in its cache of the judging system, they are available in archive.

I feel lousy realizing that my lack of attention to detail has led to such consequences. I distinctly remember the black day of Codeforces — and as a result many things have been much revised (everywhere mirrored disk arrays, replicas and backups). Unfortunately, this time after moving to new hardware I did not return all scripts and here is the result. Problem writers please accept my deepest apologies for my mistake.

Full text and comments »

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

By MikeMirzayanov, history, 10 years ago, translation, In English

Hi!

I know that it will be obvious for real C++-masters, but for me it is small surprise. I used to think that signed overflow in C ++ does not cause real undefined behavior on a particular platform. That is, it is clear that depending on the big-endianness/little-endian result may be different.

I found short and funny example:

#include <iostream>
int main()
{
    for (int i = 0; i < 300; i++)
        std::cout << i << " " << i * 12345678 << std::endl;
}

Being compiled with -O2 on modern g++ it will run infinitely. Suddenly, right?

Full text and comments »

Tags g++, ub
  • Vote: I like it
  • +257
  • Vote: I do not like it

By MikeMirzayanov, history, 10 years ago, translation, In English

ACM-ICPC World Finals 2016 will take place on May, 19, 03:00 (UTC). It is one of the most important events in programming competitions life.

More than 40000 contestants from 2736 universitites from 102 countries had competed in regional competitions. 128 teams had advanced to the World Finals, which are held this year in Phuket, Thailand. Soon we will know which university takes home the most prestigious title in programming — the tile of the World Champion of ACM ICPC!

Useful links:

I wish the teams good luck and many baloons!

Full text and comments »

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