Dmitry Blog Cover
Topcoder Community

Meet Dmitry: the Mind Behind Topcoder's Marathon Matches

I first met Dmitry (dimkadimon) in person at TCO19. By then, he had already been part of Topcoder for 17 years.

He started in Single Round Matches back in 2002, moved to Marathon Matches after the TCO 2010 Final, and wrote his first MM problem in 2019. Along the way, he became a Topcoder MVP and helped run multiple TCO Marathon Match finals, as well as the Marathon Match Tournament. Today, he's our main Marathon Match writer - coming up with the ideas, building the visualizers, writing the example solutions and working with testers and QA until each problem is ready for launch day.

What I value most is that he's never lost the member's perspective. He knows what it's like to be on the other side of a problem statement, and he speaks up when members run into issues. Many of those concerns have reached me, and we've worked together to get them fixed.

It's rare to find someone who builds the competition and still speaks up for the people who compete in it. We're lucky to have him.

I sat down with Dmitry to talk about where MM problems come from, what goes into building them, the problems he's proudest of, and how AI is changing the way people compete.

For members who don’t know you yet, what do you do at Topcoder today, and how did you get there?

Hello my name is Dmitry, and I am dimkadimon at Topcoder. I have been doing Topcoder since 2002. For a long time I was only doing SRMs (Single Round Matches). Then at the TCO 2010 Final I was fortunate to meet two people who convinced me to try Marathon Matches: Nickolas (long-time Marathon Match writer) and Psyho (the most successful Marathon Match competitor of all time). I started competing in Marathon Matches and really enjoyed them. Then in 2019 I tried writing my first Marathon Match. It went quite well and somehow I became the main Marathon Match writer. Since then I have been writing, testing and managing Marathon Matches.

Where does a Marathon Match problem idea actually come from?

My Marathon Match (MM) ideas come from many sources. Some of them come from puzzles that I create. Others from events that I see in real life, like Marathon Match 145, which was about controlling lifts in a building - just like the one I live in. A lot of the ideas come from board games and computer games. Recently we had problems about Scrabble (Marathon Match 167), Battle Ships (Marathon Match 165), Chess (Marathon Match 161), Mini Golf (Marathon Match 159) and Reversi (Marathon Match 156). One problem even came from an unusual carpet design in my parents' living room :) Marathon Match 152, original puzzle containing a photo of the carpet: https://puzzling.stackexchange.com/questions/122620/colouring-a-rug)

Walk us through a problem from first idea to launch day. What happens in between?

There is a lot of work involved in making a Marathon Match problem. First you need to have a good idea. You need to make sure that it is original, interesting, allows multiple approaches, has sufficient depth and so on. I keep a list of good ideas and use it to select the next problem I am going to write. Once I have an idea I share it with my tester just to check that it is worth using. After that I start writing the visualiser (more on that in the next answer).

Once I have a draft visualiser ready I share it with the tester who tests the problem. This involves checking that it works correctly, that the parameters make sense, that the scoring function is appropriate, and that the visuals are easy to see and understand. This is a back and forth process that continues for a few iterations until we reach a point where we are happy with the problem and the visualiser. Then I write the problem statement, create the animation, and write all the example solutions.

All of these get tested and verified by the tester. About one week before launch, our helpful QA team sets up the problem in the development environment. They perform further testing and let us know if there are any issues. The tester also submits his own solutions and checks that everything works as expected. Just before the launch, I write a brief problem description and DaraK sends it in an email to everyone. She also shares the launch on our social platforms: Discord, Facebook and YouTube. The launch goes ahead and we pray that everything works.

Every MM problem comes with a visualizer. What goes into building one, and which visualizer is your favorite?

The visualiser is the core of the problem. It starts with the generator method. This method must generate a random case, based on a starting seed. It must set up all the variables and assign the parameters that are passed to the solution. The next part is the "bridge" between the visualiser and the solution. The visualiser must send all the input to the solution, read its output, update the internal state and produce the final score. It should also check for illegal commands and incorrect formatting, and output appropriate error messages. Then we have the actual visualisation part that displays the state and helps the user to debug their solution. Finally, we add a manual mode that allows competitors to play the problem manually, which can be useful for debugging.

My favourite is probably the hexagon visualiser from Marathon Match 166 - I think it's one of the most beautiful I've made.

MM 166 resized (1).png

Marathon Match 166 Visualizer

I also liked the ones for Frogger (Marathon Match 148) and the chicken run problem.

MM 148

Marathon Match 148 Visualizer

Tell us about a problem idea that didn’t make it, or one that changed a lot before it went live.

Almost all problem ideas get changed during the development phase. Sometimes the changes can be quite drastic, involving changes in the scoring function, addition of new rules or constraints. Some ideas don't even get seriously considered because we already had similar problems or they are too easy to solve.

What do you do outside Topcoder? Hobbies, free time?

Outside of Topcoder I try to stay fit with various sporting activities. I enjoy hiking, roller skating, playing football and badminton. I run a social football group where we play once a week. I also have two elderly dogs that need to be walked multiple times a day.

AI tools have changed how people compete. How has that changed the way you design problems?

I haven't changed my approach to the problem design. However I have noticed other people using more AI for writing and testing problems. AI has gotten so good that it is difficult to make problems that it cannot solve well. Also I suspect if we could make such problems then they wouldn't be much fun for the human competitors.

In a Marathon Match today, what can a human competitor still do better than an AI agent?

At this point, a strong human competitor paired with an AI can still outperform someone who just uses AI blindly, but this situation will change in the near future. I feel that strong human competitors have a good intuition about which general approaches can work well or not for a given problem. They can also find some corner cases that allow them to gain some extra points. Everything else AI can do really well and much faster than humans.

What’s the best way for the MM Tournament to stay fair both to members who use AI and to those who don’t?

This is a difficult question and we are currently discussing our options. Given that the Marathon Match tournament is well underway, it may not be fair to make drastic changes to the rules now. However, I feel that the rules about AI will need to change at some point. With AI becoming so strong, our veteran competitors are losing interest in the competition. It just becomes a battle of who has the strongest AI or more tokens to burn. On the other hand, AI allows people with little time to compete. So it seems that it is still useful to allow AI usage. One option is to have two separate divisions: human-only and human+AI. That could be a good middle ground. One problem still remains: how do we detect AI usage?

What’s a problem you’re proudest of, and why?

There have been many problems that I enjoyed making over the years. I really enjoyed HordeChess (Marathon Match 161), as it allows you to play against an AI opponent. Even though the opponent was weak, it was still challenging to do well and playing manually was fun.

MM 161

Marathon Match 161 Visualizer

Marathon Match 148 was based on my favourite Frogger game. You had to jump on passing logs to collect coins and then return them to the base. Although I feel that we made the problem a little too hard.

I enjoyed making RobotPainter (Marathon Match 140) as it was based on Logo, my favorite programming language. It allows you to make some incredible drawings with some simple commands.

Two problems really stand out for me. The first one is BouncingBalls (Marathon Match 132) where you had to maximize the number of steps that balls bounce around the grid by placing mirrors at appropriate locations. The competitors came up with some incredible strategies that I didn't expect. sullyper even managed to crash the visualiser by getting a solution that scores really high! After the competition we developed a lot of theory for the problem and even submitted an integer sequence (https://oeis.org/A350155).

MM 132

Marathon Match 132Visualizer

The second problem is HardestMaze from Marathon Match 119. This problem asked one to create a maze that forces the longest shortest walks. This resulted in some interesting patterns and led to some nice theory. Together with sullyper and wleite, we created an integer sequence about it (https://oeis.org/A335753).

MM 119 resized.png

Marathon Match 119 Visualizer

-----------------------------------------------------------------------------------------------------------

Problems get solved and leaderboards get settled, but the way someone looks out for the community stays with people. Thank you, Dmitry, for always speaking up for our members.

Related Articles