Sunday morning, 11am. While many of their counterparts are still sleeping, hundreds of young women and men have gathered at ten platforms in St. Petersburg, Petrozavodsk, Murmansk and Novgorod to take part in the qualification state of the international programming competition ICPC. ITMO University serves as one of its biggest venues, with ten rooms allocated for the participants.

ITMO.NEWS manages to catch several teams before the competition’s kickoff to ask them about their impressions. This year, the participants who qualify for the competition on the basis of the Russian North-West have encountered a couple of new measures. To allow for the participation of more teams and universities, the event’s organizers have introduced an additional qualification round, which anyone willing can participate in at one of the venues in their home city. Before, participants had to go to St. Petersburg to take part in the first round. The new procedure allowed to attract 200 teams (with three people in each) and some ten new universities. But the introduction of a new round elicited very different responses. 

“This is our first time participating in ICPC,” shares Yaroslav Zaruchevsky, a member of one of the teams representing A.F. Mozhaysky’s Military-Space Academy. “I think that the qualification round opens up new opportunities and makes it easier to make a decision to participate. At my university, there are lots of students willing to take part in such competitions. As soon as we learned that there would be a qualification round, it took us half an hour to make a team.”

The qualification round of ICPC in the Northwestern Federal District of Russia
The qualification round of ICPC in the Northwestern Federal District of Russia

Nikita Gayevoy, a representative of St. Petersburg State University and semi-finalist of last year’s ICPC, believes that the introduction of a new stage only makes the selection process much more complicated.

“In my opinion, it’s just one more round that you have to pass in order to be eligible for participation,” he says.

In his turn, Andrey Kuchma, a first-year student at ITMO University, welcomes the opportunity to participate in the qualification round of the famous programming competition. 

“I think that it wouldn’t hurt to take part in ICPC if you’re an ITMO University student, what with us being surrounded by world champions and everything. You can gain new experiences, and this also makes for good training. I’ll definitely be participating next year,” he says. 

A chance for everyone

After a short trial round, the participants are ready to start qualifying. In the course of five hours, they have to solve twelve tasks, each then will be checked by a computer. Out of 196 teams participating in the qualification round, 120 will be selected.

“Qualification round operates on a very positive formula,” comments Andrey Stankevich, one of the competition’s organizers and all-time coach of ITMO’s programming team, after the competition’s official kickoff. “Firstly, each participating university is guaranteed to see their best team invited to the quarterfinals, even if it comes in at a place before last and solves only one task. As for the universities’ second and third teams, the 40 best will also make it to the quarterfinals regardless of their position in the overall rankings. Coming next will be other teams in the regular leaderboard order so that we have 120 teams that will go on to the next round in the end.” 

The qualification round of ICPC in the Northwestern Federal District of Russia
The qualification round of ICPC in the Northwestern Federal District of Russia

What is special about the qualification round is that the tasks here are not very complex. They are hard enough to bar from participation those teams that aren’t ready for the next round and simple enough so that anyone with at least basic knowledge of programming could solve them and understand if they’re interested in this field or not.

“The first couple of tasks are more maths-based, they won’t require you to write a code longer than four-five lines,” says Andrey Stankevich. “They’re accessible to anyone who’s had informatics lessons at school. At the initial stage, we are talking about some very familiar tasks: say, a train left point A for point B, what’s needed is to calculate its distance knowing its speed and time and with its exact data being the only thing that’s omitted. You need to write a program that solves the problem with any data that is entered by a user. Nowadays, it’s not only computer programmers who need computer literacy, but also physicists, biologists, and chemists. We at ITMO have a rather rare situation now, in that lots of teams that represent us aren’t from our programming faculty. One of our top teams, for example, features a physicist.”

While we are talking, the first hour of the competition comes to an end. Two confident leaders have already been identified: the Havka – ne papstvo team from St. Petersburg State University and the Standard Deviation team representing ITMO University. While many teams have solved only one task, these two have already solved nine. Another ITMO University team closes the top three with eight completed tasks.

Tough race

The qualification round of ICPC in the Northwestern Federal District of Russia
The qualification round of ICPC in the Northwestern Federal District of Russia

After the competition kicks off, participants can only communicate with each other. Phones, tablets, books and notes are prohibited. The only thing you can take with you is food and water, as you are not allowed to go out for a snack in the following five hours either. There are chocolate bars, cookies, energy drinks, water, and juice on the tables. However, participants don’t really have time for all that. Everyone is completely immersed in solving tasks: someone writes something down in a notebook, someone writes a code, someone thinks out loud.

“When a team approaches a problem mathematically, it involves coding on a computer,” continues Andrey Stankevich. “You have to either write a program in a development environment or in a text editor in the programming language chosen by a team. You can then test the resulting solution, see how it works, as the task includes an example of the input data and expected answer. In terms of its complexity, this process is the same as attaching a file to an email.” 

After that, the system checks the program and either marks the task as completed or informs the participant about a mistake. In this case, the team can solve the task again, but this is taken into account in the final table. If, when the competition comes to an end, the number of completed tasks is the same, the team that hits the most in fewer attempts wins. So, two hours later, the Standard Deviation team (from ITMO University) left its closest competitors behind. Both teams solved ten tasks each, but the representatives of St. Petersburg State University needed as many as five attempts to solve the seventh task.

Andrey Stankevich
Andrey Stankevich

ICPC isn’t only a competition of who codes better. This is a tournament in which even the top players are subject to enormous psychological and even physical strain. Three hours in, tables are almost empty of food; there are only wrappers around. Rooms get as stuffy as school sports halls. As per the rules of the competition, there is only one computer per one team, which is why sometimes members of some teams switch their places to let someone rest from writing code and someone from writing solutions. One exemption from this are the teams who came not fully assembled with one or two of their members missing. Nevertheless, the quarterfinals will require all teams to participate en masse. 

“It so happened that when it all just started, there weren’t enough computers for all participants. That’s why this kind of sports programming has become a team sport,” explains Andrey Stankevich. “After a while, it became obvious that it’s much more fun to play in teams: while one participant is writing a solution, the rest of the team can continue brainstorming and solving other tasks. The teams are all very different – there are some 30 teams from ITMO University only, each with its own strategy and tactics. There are teams with excellent mathematicians and programmers, and while the former are solving tasks, the latter are turning the solutions into code. In ITMO teams, all participants are pretty good programmers so that they can work in shifts.”

Teams always have access to the leaderboard so that they can see how many tasks have been solved by whom and in how many attempts. This helps you keep track of your position relative to your competitors and assess which tasks are easier for other teams to solve and which cause difficulties for the majority of participants. An hour before the end of the tournament, the leaderboard freezes, meaning that participants can’t update it, which intensifies the intrigue. Leading this time was an ITMO University team with 11 tasks solved, the same number as their rivals from St. Petersburg State University. Following them closely were three other teams from ITMO, five teams from St. Petersburg State University and two teams from Higher School of Economics, each with ten tasks solved.

The qualification round of ICPC in the Northwestern Federal District of Russia
The qualification round of ICPC in the Northwestern Federal District of Russia

“The fourth and the fifth hours are the most important ones,” explains Stankevich. “This is when participants get to more complex tasks and start getting tired. This is when it’s crucial to do your best to perform well.”

Waiting for quarterfinals

After the results table gets updated again, it becomes clear that emerging as winners, only in terms of the attempts made, is the team Standard Deviation; these ITMO University representatives managed to finish off the last task in the competition’s final hour, though it took them four attempts to achieve this. Also coming to their benefit was the fact that they solved a whopping five tasks fastest of all the participants. Coming in second were the participants from Higher School of Economics, with St. Petersburg State University representatives in the third place. All in all, only five teams managed to complete all 12 tasks.

The qualification round of ICPC in the Northwestern Federal District of Russia
The qualification round of ICPC in the Northwestern Federal District of Russia

A total of ten ITMO University teams have made it to the top-25. 31 ITMO teams have made it to the top-100 of the qualification round.

Almost all teams have managed to solve three tasks or more, and only 18 teams out of 196 failed to complete at least three tasks. As noted by the organizers, these results should show to the maximum number of universities that for their students, participation in ICPC can be a good start which can possibly lead them to programming. This competition is not something students have to be afraid of, even if they lack the necessary knowledge and skills.

The 120 teams selected will gather at ITMO on October 26 to take part in the competition’s quarterfinals. After that, the best representatives of the participating universities will be selected to compete at the final Northern Eurasia round (ICPC semi-finals) set to take place in December 2019. The company Huawei will serve as the round’s gold sponsor. The company’s representative Denis Shitov also attended the qualification round to have a look at the team’s performance and discuss the details of the following competitions with the organizers.

Denis Shitov
Denis Shitov

“We’re supporting this competition because we believe that it can help young talents in the ICPC community. It’s also important for us to demonstrate the real-world activities of Huawei, and how large is the scope of our developments and research,” explains Denis.

The best young programmers from all over the world will gather at the ICPC 2020 finals in Moscow, which will be hosted by the Moscow Institute of Physics and Technology.