piaoyun's blog

By piaoyun, history, 6 weeks ago, In English

In the recently finished Round 1112, I somehow got retked by a Div. 1B for two full hours for no apparent reason. I knew my approach was right, but there was some very very tiny bug somewhere in my code.

Wait, why not ask GPT to debug the code, quickly move on to the next problem, and avoid having my entire evening fxxked? The thought flashed through my mind, but instead, it inspired a more interesting question: when faced with a long and painful debugging session, and the option of using “a little magic,” how many people would choose the latter?

Since GPT can debug almost any problem, if many people choose the latter, then we should be able to observe that once something goes wrong with a problem during a contest, the probability of eventually solving it becomes much higher than it was before GPT.

So I asked my Codex to collect submissions from recent years and calculate how the debugging success rate has changed each year. Here, the success rate is defined as follows: after a submission receives a WA, RE, or another failed verdict, whether the problem is eventually solved before the contest ends.

The result was shocking. In the pre-GPT era, this value remained stable at around 53%. It began to rise in 2025—GPT-5 was out—and reached an astonishing 69.0% in 2026.

This means that if we assume the success rate of purely human debugging is 50%, while GPT’s success rate is 100%, then approximately 38% of contestants who face with difficulties ask GPT to “help a little.”

Of course, this statistical result may not be particularly professional. I hope someone else can reproduce it and produce a more rigorous report. But for now, it seems that the entire competitive programming community has gradually learned to “coexist” with GPT.

Full text and comments »

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

By piaoyun, history, 3 months ago, In English

I think many people now hold such an idea: LLMs have already historically defeated CP, and catching those cheaters is only useless effort. The fairness of CF and the value of rating will finally disappear.

But, is CP the first game where humans were defeated?

Long time ago, Deep Blue defeated chess, AlphaZero defeated Go, scripts and mouse macros defeated FPS games, and GTO defeated Poker. The fact is, chess developed faster time controls that are harder to cheat in. Thousands of millions of real money still flows on poker websites. FPS game companies rely on automatic detection and community anti-cheat to continuously reduce the percentage of cheaters in the game, until it reaches a level that can basically be tolerated.

In this article, I list some anti-cheating methods that I know. Maybe not all of them are feasible. But what I want to express is that we still have many methods to defend the purity of the CP community.

1. KYC (Know Your Contestant) & VP (Verified Player)

First, we need to recognize that there is a huge cost asymmetry between cheating and anti-cheating today.

Because of some kind of insistence on “open-source spirit”, Codeforces still has no effective restriction on one person registering multiple accounts. In every contest, there are thousands of alternate accounts joining. Obviously, the energy of CF managers is limited. They pay more attention to removing cheaters within the top 200, and have to tolerate huge cheating in the rating range below 2400.

However, most ordinary users are the ones who support the Codeforces community. They might also become future GMs or even LGMs. Hurting their feelings toward CF will certainly harm the future of the community.

I think firstly one phone number should be limited to only one CF account. If you want to cheat, then you should be prepared to lose the convenience of using CF later.

Second, we should allow users to become further Verified.

The standard of Verified, in my definition, is that you can prove your strength through a trusted third party, or that if you are found cheating, you will pay a relatively high cost.

To become Verified, one needs to satisfy any one of the following conditions:

  1. Verify an award from any offline contest, such as ICPC, UCup, OI in any nation, like NOIP or CCO.
  2. The account was registered before the LLM era, for example before 2025, and already had a rating close to the current level at that time.
  3. Complete student verification and confirm that you are a student of some school, so that the community from the same school can play a role of supervision.
  4. Pay for the account.

When calculating the final rating, Verified players will only be calculated based on other Verified players, and non-Verified players will be “skipped”. Non-Verified players also use Verified players as the standard, but they will not have an influence on the latter. (which means, the rating of a Non-Verified player is based on his performance against other Verified players

After that, we can selectively ignore anti-cheating review for non-Verified players.

Through this method, non-Verified players can get a fake rating to satisfy their vanity, but they will no longer hurt other honest players. At the same time, the experience of new players joining contests and getting rating will not be affected.

2. Hack the Cheater

A large number of honest CF users have already mobilized to find cheaters, and summarized many features of AI, such as overly engineered naming, overly defensive programming, and so on.

Unfortunately, the enthusiasm of these users has not been effectively used for now.

I want to introduce the anti-cheating experience of Perfect World Platform in CS2. It is mainly divided into two types:

  1. PAC, or Perfect Anti-Cheat. The official side collects features through automatic programs, with human intervention.
  2. CAC, or Community Anti-Cheat. It is a community formed by green players, similar to a jury system, which evaluates and votes on recordings of suspected cheaters.

First, Codeforces should open a report function, allowing users to submit evidence of suspected cheaters. After that, other Verified players can review the code of reported players and vote.

This process may cause false judgments. Therefore, we can use a mild method for damage control. If a player is judged by the community to have cheated in this contest, this player will not affect the rating of other players in this contest. But he himself can still get rating normally, and there will be no display on his profile.

The case will be further submitted to administrators with higher authority, who will make further decisions.

3. Possible Future Anti-cheating

Anti-cheating from the source of LLMs may be very hard, but it is also the most effective.

Take Poker as an example. The largest GTO provider, GTOWizard, has always cooperated with major poker websites and provided methods to detect cheating, including checking whether some hands were queried in GTOWizard, and whether the actions of players match the suggestions of AI.

During the Chinese Gaokao (National College Entrance Exam), many local AI companies closed image recognition functions and refused to answer questions that might be related to exam problems.

LLMs do not only affect Codeforces. They also affect the fairness of exams around the world. Maybe in the future, there will be a database jointly maintained by global educational institutions. They can upload exams that are currently happening, and LLMs can check the database before answering questions, then choose whether to refuse answering.

This will not be pushed forward by Codeforces or some university alone, but will be produced by cooperation of the whole society.

Final Words

CP and Codeforces were once my belief, because it is open to everyone, and is always objective, fair, and equal. Anyone has the chance to realize himself. I absolutely do not want to admit that it will be easily defeated by technology.

I sincerely hope that everyone can restore confidence and solve this hard problem together: to defend the sacredness and honor of our cause.

Full text and comments »

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

By piaoyun, history, 4 months ago, In English

It is the running Round 1094 Div 1 + Div 2 actually.

Every two weeks, I will be sitting in front of my pc and humiliated for three straight hours. I love post-GPT CP so much.

Full text and comments »

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

By piaoyun, history, 11 months ago, In English

Guys, I’ve been trying to come up with a solution that could partially mitigate the impact of GPT cheating. It’s obvious that right now there’s a serious imbalance between the cost of cheating and the cost of anti-cheating measures, and this cannot last forever. My proposal focuses on:

Increasing the cost of cheating.

Increasing the benefits of anti-cheating.

Reducing the impact of cheating.

Before diving in, let me briefly introduce the two major models in the blockchain world: POW and POS. POW was introduced by Bitcoin, relying on something like “computational power voting” to determine the validity of transactions. This requires maintaining more than 51% of the computational power on the side of the honest participants, which comes at a huge cost. POS, on the other hand, introduces validator nodes, each of which must stake a significant amount of tokens. If they are caught producing malicious or false information, their stake is slashed. This makes the cost of malicious actions much higher. At the same time, these stakers need rewards, so POS currencies tend to inflate and distribute newly minted tokens to validators.

Now, let’s propose a Codeforces Token. Player accounts can voluntarily stake a small amount of tokens (say, $10) to enter a “staked” state. We can treat staked players as competing in rated contests. If they are caught cheating, part of their staked tokens will be slashed. Unstaked players can still participate, but they will only get a Virtual Rating. This rating is calculated based on the results of staked players and only affects their virtual rating changes. The results of unstaked players will not affect the ratings of staked players.

This way, we can essentially ignore anti-cheating checks for unstaked players (who are often just mass-created accounts), because they don’t affect fairness. At the same time, we don’t restrict anyone’s right to participate in contests. Additionally, special Codeforces platform rewards (such as CodeTON, 20xx is NEAR, etc.) would only be distributed to staked users.

A user might choose to purchase tokens and stake them for the following reasons:

They want their rating to be officially backed by Codeforces.

They want to support the Codeforces platform.

They want to earn contest rewards.

Regardless of motivation, when a player decides to retire, they can sell their tokens, bearing only the cost of market price fluctuations. Codeforces could even distribute enough tokens for staking to all accounts registered for at least one year, so no one actually has to pay upfront.

The Codeforces Token could also be inflationary. After each contest, new tokens are minted. Staked players can rate the contest: an upvote will direct the newly minted tokens to the contest organizer, while a downvote will burn them. This incentivizes organizers to hold better contests.

What do you think? I truly believe in this idea. If such a token really existed, I personally would buy $1000.

Full text and comments »

  • Vote: I like it
  • -42
  • Vote: I do not like it

By piaoyun, history, 2 years ago, In English

I must say that I have no ideas about the details how OpenAI tested o1 model in IOI and Codeforces contests. This framework may not work or they have tried it.

Here are some facts:

  1. o1 performs relatively poor in IOI with 50 tries each.

  2. o1 achieves IOI Gold Medal with 10000 tries each.

  3. o1 only achieves 1600+ rating (far from IOI Gold Medal) on Codeforces.

  4. According to the survey by community (https://codeforces.me/blog/entry/133887), o1 can solve very hard problem (2700) but also fail some very easy problems (800)

  5. Codeforces's rule prohibit o1 from having too many tries.

4 and 5 may be the reason why o1 only achieve 1600 on Codeforces. The difference between IOI Gold and 1600 is, that IOI rules provide a no-cost validation so its final score is max(for each try).

I believe, OpenAI didn't pay much attention to how to conquer the submission limitation of Codeforces. They may also independently generate 50 or 10000 codes. Thus the potential of AI cheating is suppressed and can soon threat to higher rating players.

The point is, is there a way to validate each piece of code without submitting it? YE5.

Any well-trained CPers / OIers may easily come up with their practice in some contests where participants can only submit once. They write a pretest generator, a true but slow brute-force solution and their final solution. Keep comparing the results of both until after a bunch of tests there is a difference or not.

Brute-force is always easier to write, some extremely slow brute-force like exponential algorithms can hardly be wrong. Solving problems iteratively is the common experience of us.

So the simple framework works like this:

  1. generate and validate an exponential solution can pass all given pretests.

  2. generate larger pretest and use the exponential solution to validate newly generated n^2 solution.

...

  1. generate total scale pretest and use previous fast solution to validate final solution.

  2. submit

If it's stuck at step 2 for a long time. The exponential solution is wrong, generate a new one and ask for more human-made pretests. The validation process may consume much time and should be accelerated with multi-threads strategy. Also next stage solutions and be generated and validated parallel.

Full text and comments »

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

By piaoyun, history, 3 years ago, In English

I don't mean setting a rating limit like only pupil or higher people can post a blog or send talk . That's discrimination.

But asking who writes comments to participate in at least one Codeforces contest is proper , even they get WA on A and don't pass any problem.

I'm just sad to see many spams and disrespectful comments due to many causes. People want to make spoofs but don't want to get downvoted, so they create another account. Most of them are children under 14. I hope this can help to increase the time cost of it.

No kid would create an account ,wait for another contest, just to look funny in public , I think.

Full text and comments »

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