Una_Shem's blog

By Una_Shem, 5 years ago, translation, In English

Hi, Codeforces!

My name is Una and recently I became a part of the Codeforces team. Unfortunately, I’m not a programmer, but I’m happy to help with other things. For example, if you win a T-shirt, you'll receive a message asking you to update your personal information, and I do it. ;)

As a new person in this area, I am interested in all the news. Recently I read an interesting interview with the legendary Gennady tourist Korotkevich on the ITMO news portal. The interview is dedicated to the victory in the “Science and Life” category of the "TOP 50. The Most Famous People of St. Petersburg" award of the Sobaka.ru magazine. Codeforces team join others in congratulating!

The editors of the portal allowed to share the article on the Codeforces pages (and we are very grateful for this). Original article published at http://news.ifmo.ru/ru/university_live/achievements/news/8550/.

Gennady doesn't often give interviews, and this is especially noteworthy because it was taken by people whom he has known for several years. The interviewers are Anatoly Shalyto (Head of the Programming Technology Department) and Lidia Perovskaya (Assistant of the Programming Technology Department). And I thank them and Gennady for such an interesting article!

What does a two-time world champion in competitive programming do as a student? Why does he continue to take part in competitions, and how does he choose them? Would he like to be named “Hero of Belarus”? Gennady Korotkevich, a PhD student at ITMO University and the recent entrant of Sobaka.ru Magazine’s Top-50 People of St. Petersburg list, answered these and other questions in an interview with Prof. Anatoly Shalyto, himself a member of Sobaka.ru’s 2017 edition of the Top-50, and Lidia Perovskaya, ITMO graduate and producer of ICPC World Finals live broadcasts.

Gennady Korotkevich. Credit: rb.ru

Anatoly Shalyto: the Science and Life category of Sobaka.ru’s contest is a tough one to compete in. It would seem that science and life should be awarded separately. In 2017, I split the honors with Grigory Sverdlin, who runs the Nochlezhka charity foundation for the homeless. Among the nominees were “three” scientists (one was actually five people) and the representatives of four foundations. In 2019, the list included four scientists and the founders of a charity organization.

We were nominated for ITMO University’s successes in programming competitions and proudly announced that the University had just become the world champion in programming for the seventh time; the awards ceremony took place mere days after our victory. The reaction of the audience was telling: they understood just how unprecedented an achievement that was.

Last year, the award in the Sports category of the Top-50 went to the athletes who came third in the European Figure Skating Championships. I should note that our city dearly loves the Zenit football club, who were recently crowned as Russian champions, but a national championship can hardly be compared to Gena and ITMO’s achievements. We became world champions seven times and won international competitions by succeeding over tens of thousands of teams from thousands of universities from all around the world.

When Gena had won five of the world’s top individual competitions in the same year (which we referred to as the Grand Slam of programming), I submitted an article to Peterburgsky Dnevnik, the newspaper published by the administration of St. Petersburg. They published it… on page 13, with a photo of Zenit goalkeeper Yuri Lodygin on the cover, who didn’t even have his title yet. Since 2010, I’ve been trying to promote the idea of creating a federation of competitive programming: first on a national level, then internationally.

Lidia Perovskaya: Gennady, one of the Sobaka.ru award’s categories is named Sports. Do you think it would have been more accurate for you to win in that category?

Gennady Korotkevich: “Sports” is more about official types of sport, I think. I’m not sure you could my activities as the sporting kind. Competitive is more apt.

LP: How many times did you personally meet the President of Belarus, a country where you were born and raised?

GK: I met President Lukashenko six times in a row, from when I was 12 and until I was 17. There is a special Presidential Foundation for the Support of Talented Youth in Belarus, and every year, usually in May, they would have an awards ceremony. Talented school students usually get awards in two categories: science and art. The winners of international competitions are automatically considered laureates of the prize. I won medals at the international olympiad in informatics seven times and was invited to meet the President six times. I don’t even know if there’s anyone who was invited there more times than I.

I did not get invited after 11th grade. I was a first-year student at ITMO University, and the olympiad took place in September even though it was usually in the summer. Some of the participants were already university students. I placed second. When I was younger, university students were still invited to the ceremony. They’d say: “Graduate of school so-and-so, currently a student of University such-and-such”. But when I went to university, I didn’t get invited. One could only guess why.

AS: Would you like to be named Hero of Belarus like the biathlete Darya Domracheva? She was an Olympic medalist three times, and your list of achievements seems bigger.

GK: I understand that people who excel at sports are often recognized by the state, but I think you don’t get the Hero of Belarus title just for being a champion. Darya is very well known in Belarus; pretty much every second person knows who she is. People who take part in programming competitions aren’t known that well. Titles like this are, among other things, a reflection of popularity. Recognizing programming as a type of sports is absolutely a way to popularize it, but its efficiency is debatable. The game Go has its federation in Russia, yet its players are still not popular among the general public.

LP: How important is it for you to have this kind of recognition? Andrey Stankevich (the coach of ITMO University’s programming teams) has an ICPC Senior Coach Award. Do these titles have any value to you? Or maybe how long you’re able to hold the first place in some ranking?

GK: As for Stankevich, everyone in our international community knows how awesome he is. That’s because they watch the competitions and know him as the coach of seven ITMO teams who won the champion title.

Becoming a Merited Coach of Russia would elevate his image in the eyes of other specialists. Competitive programming is not the sport of millions. Winning any competition is a great achievement, and so is earning a title, but victories matter to me more because they are objective. Titles, as pleasing as they are, only represent the subjective opinion of others. I don’t know for how many weeks I’ve topped the rankings. My dad keeps track of that.

Not long ago, a boy from Gomel came to the computer science competition at ITMO University and really wanted to take a picture with me. That must mean I’m setting some kind of example.

As for me, when I was just starting out in school, Petr Mitrichev was winning many competitions. You could say I was taking cues from him. He began relatively early, five years before I did. He’s about ten years older than me: he got his start in grade six, and I in grade two. He went to the ICPC finals twice and finished second each time even though he was at the top of every ranking at the time. This was the result of an unfortunate set of circumstances, but he won many other competitions. He’s now noticeably older than the ones taking part in student competitions, but it doesn’t stop him from showing great results and winning.

When they measure your success, people usually consider two things: victories in international competitions (ICPC, IOI, Google Code Jam, Facebook Hacker Cup, etc.) and your ranks on websites like Codeforces. And those in the top-10 always get questions from newcomers along the lines of “How do I get as good as you?” I suppose that means they see you as a model.

AS: I once phoned you after Barcelona beat Paris Saint Germain and said: “Gena, Barcelona just won Korotkevich-style”. You replied: “I’ve never lost 0:4, even on away games”. To which I said: “Just as I thought, you’re even better than Barcelona”. Do you ever play football of any kind, be it the real thing or tabletop?

GK: I did at school. The last time I played was in February during a competition in India. They had set up a futsal tournament for us, and we played in teams of five. When I was in school, I played table tennis but never took it up professionally as I already became heavily involved in programming.

I still play for pure entertainment, like during the ITMO University championship. I even played for the university’s select team several times. Our University hosts an open championship several times per year, and the last time we had 20 really good players from around the city. I beat a couple of them, which was pleasing. I even entered the top-3 among ITMO students a few times.

AS: I’ve read somewhere that you had the opportunity to enroll in any technical university in third or fourth grade. How’s that?

GK: The school system in Belarus was going to consist of 12 grades. Then they decided to renumber them, and we ended up with grade zero, first, second, and then the whole country would graduate from second grade and go straight into fourth. Then they decided to bring back the 11-year system, and I ended up finishing 11 grades. All subjects have a separate competition for each grade except for computer science, which has one shared competition for all. As I neared the end of second grade, I entered the computer science competition and unexpectedly ended up in the national top-45.

AS: And you could enroll in university?

GK: Not really. In Belarus it’s like this: if you win as an eleventh-grader, you can go to any university, but if you win as a tenth-grader, but lose next year, you’ll have to apply like everyone else.

LP: How long did it take to prepare for every competition?

GK: ICPC and IOI both last five hours, so when you start training, many days consist of a five-hour simulation followed by analysis and discussion of the tasks. And that might last a week or more, every day.

LP: Many programmers stop taking part in competitions after going to ICPC for the second time: work starts taking up too much time or they find other interests. You’re one of the few who keeps taking part in other events. What’s your motivation?

GK: Competitions change. Programming and IT science are developing quickly, and competitions follow suit. Sometimes you’ll get a task about an algorithm that has just been invented. The article just came out, and yet it’s already there.

If you don’t train regularly and do nothing for six months after ICPC, you’ll find it hard to get back. Many great programmers, even world champions, who stopped training and taking part soon feel that they are unable to compete at the same level. To many, competitions are a way to prove to yourself and others how cool you are. Once you start to realize that everyone around you is young, spry, and clever while you’re not doing as well as you used to, you obviously lose motivation, and this leads many people to stop taking part.

I don’t stop training and I keep myself “in shape”. Of course, I still compete less than I used to when we were training for world championships, but I still do it often enough. Our team members get together at least once a month and compete alongside active teams. What’s also important is that I haven’t stopped winning. If I did, perhaps I would have retired, but for now, I’m still doing fine.

AS: I’ve just learned that you’re not doing fine with just programming. One of our staff told me that an article you co-authored got accepted by a high-profile bioinformatics journal. How did you do on your Master’s thesis? Do you plan to keep working with bioinformatics?

GK: My scientific advisor, Alexey Sergushichev, often comes in contact with tasks of an algorithmic nature. Of course, scientific work is more than just algorithms and theory. Bioinformatics is a very practical field, but at some point, he encountered a problem and asked me how to approach it, so I spent a couple of months thinking on it in the background. It was a bioinformatics task, but Alexey presented it to me in an abstract manner, which to me is more interesting. Perhaps his having taken part in the national programming championship played a role.

I think that people involved in science, even if they’ve never taken part in computer science or programming competitions, understand very well what an algorithmic problem is. You don’t need to be a world champion to do that. Many of those working with biology and physics encounter programming in their work and must be able to program at least at a beginner level. And, inversely, there are many things about biology that programmers, even champions, won’t understand at first.

I met Alexey yesterday and he gave me another task to solve. From a scientific viewpoint, those who take part in competitions are good at solving these complex tasks as long as they’re properly formulated.

We could come up with a format that scientists would use to formulate the problems that arise in research and give them to those who have spent their lives solving algorithmic problems. Science isn’t all about solving complex problems. It’s also about experiments, ideas, publications, bureaucracy.

LP: Is it true that prize money is a significant source of your income, if not the primary one? There’s a poster hanging in the university where you’re holding a check for 1,048,576 rubles – even for a team of two, that’s still a million. That’s a lot of money for one event, though it’s not the million dollars for a team of five, as seen commonly with eSports. How important is prize money to you – both as a means of financial well-being and as a way of choosing which events to take part in?

GK: I rarely ever decide not to take part in a competition because it doesn’t pay well. There are some events that I want to compete in just because they exist, even if they’re not paying for travel and living expenses: they just have great tasks, interesting competitors, it might just be fun. But most competitions do cover the cost of travel and lodging, invite you to job interviews, and so on. As for my income: I suppose that prize money is indeed a significant part of it.

LP: Are there competitions in which you care about winning more than in others?

GK: It changes with time. When I took part in school contests, IOI seemed like the final stage. Before that, I won the national competition, which was really cool. In a sense, you achieve everything in small amounts, taking small steps towards a big goal. Then the goal shifts. Once, IOI was the goal: I won three times and came away with gold medals.

The first time I went to IOI, I didn’t have any serious expectations. I won the silver prize and was close to the gold. I was disappointed that it wasn’t gold, even though silver was also pretty great – I was still in fifth grade. I wasn’t counting on the gold anyway. What disappointed me was that they were giving the medals to everybody one by one. First, they give out 50 silver medals, then the 25 golden ones. They kept naming other people, and I was hoping for them to run out of silver and start giving out gold. I ended up being the second-to-last to get silver. It hurt, but that quickly passed. Losing only made me want to win; had I gotten the gold, maybe I would have just grown full of myself and never went any further.

Losing at my fourth IOI was a disappointment. Getting the second place after winning three times in a row hurt, but that, too, quickly passed. It was clear that I had proven everything I needed to prove. Then there were the ICPC victories and the five wins at Google Code Jam. It’s hard to say which was the most important to me. Of the “elderly” competitions (Gena is 24 years old) which I’m taking part in, Google Code Jam is the biggest achievement to be proud of.

My last year’s victory at Topcoder Marathon was, to me, a great achievement because it is a format very different from traditional contests: 12 hours, one complex task, no ideal solution. I’m still not sure if I didn’t simply get lucky there: perhaps I’ll have to win another time just to prove that it wasn’t all luck.

 Gennady Korotkevich. Credit: rb.ru

In a sense, this is what happened to me in high school at math competitions. I was still taking part in programming contests but also had the chance to take part in a math competition, which I couldn’t do before because of conflicting schedules. Now that I could take part in both, I wanted to win both. There was a chance of failing, but I was ambitious, and I did win. That made me proud. It’s always great to set new goals, keep trying, keep training, and then achieve those goals.

LP: How important is the travel aspect of what you do?

GK: Travel is great. I don’t much like flying, and I don’t much like visas, but it’s exciting to come to new countries, especially when you meet people you know from other competitions. I always try to find the time to explore the city/country, to travel around. If all the competitions took place online, it wouldn’t be as fun. Bringing all the finalists to one place matters. It motivates you. I always bring fridge magnets from wherever I go – for myself and my mom.

I really loved Tokyo. I also plan to go to Australia. I actually haven’t been anywhere in the southern hemisphere.

I wasn’t very impressed with Thailand despite its reputation as a resort country. During a competition in 2011 we all lived in a comfortable, high-end hotel, but when we went to Pattaya, it was all quite dirty.

I’m not very demanding of comfort, but I’m no fan of extreme conditions either. Ideally, I’ll need a room and a bed, living alone or with those I know. Hostels aren’t my thing. And neither is living next to strangers. I don’t have any particular requests from hotels. I never wanted to and never flew first class. I never even got a random upgrade, even though I’ve been on many flights. If there’s a seat and somewhere to fit my legs, I’m fine.

I travel home on the St. Petersburg-Gomel train, which takes 17 hours to go one way. You can’t even get to Gomel on a plan, only by flying to Minsk and then taking a train. Going all the way home on a train is great, and you get plenty of time to sleep. I might even take a . When traveling, I always try to fit my things into a single backpack, as I really don’t like checking-in my luggage.

An abridged version of this interview was published in the June 2019 issue of Sobaka.ru magazine, p. 214, 215.

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

| Write comment?
»
5 years ago, # |
  Vote: I like it -10 Vote: I do not like it

"Many great programmers, even world champions, who stopped training and taking part soon feel that they are unable to compete at the same level". You forgot Petr.

»
5 years ago, # |
Rev. 3   Vote: I like it -18 Vote: I do not like it

ACRush will defeat your Legend in google code jam finals.

»
23 months ago, # |
  Vote: I like it +10 Vote: I do not like it

I just keep on getting amazed by the sheer composure of this man!