acm-icpc-problem-setting

Use when preparing algorithm competition problems for ACM-ICPC, CCPC, Codeforces, or similar contests, including problem creation, statement writing, test data generation, and contest organization

Safety Notice

This listing is imported from skills.sh public index metadata. Review upstream SKILL.md and repository scripts before running.

Copy this and send it to your AI assistant to learn

Install skill "acm-icpc-problem-setting" with this command: npx skills add lihaoze123/my-claude-code/lihaoze123-my-claude-code-acm-icpc-problem-setting

ACM-ICPC Problem Setting Best Practices

Overview

Comprehensive guidance for creating high-quality algorithm competition problems, covering the full workflow from idea conception to publication.

When to Use

  • Creating problems for ACM-ICPC, CCPC, Codeforces, or similar contests
  • Writing problem statements with LaTeX
  • Generating test data using testlib
  • Setting up validators and checkers
  • Organizing algorithm competitions

Quick Reference

TopicDetailed Rules
Problem conceptionrules/problem-conception.md
Statement writingrules/statement-writing.md
Test data generationrules/test-data-generation.md
Special Judgerules/spj-checker.md
Time/memory limitsrules/limits-subtasks.md
Contest organizationrules/contest-organization.md

Core Principles

Problem Quality

  • Original idea - No duplicates or trivial enhancements
  • Clear statement - Every concept defined, no ambiguity
  • Complete constraints - All variable ranges specified
  • Strong samples - Catch wrong interpretations

Data Quality

  • Edge cases - Min/max values, boundary conditions
  • Diverse constructions - Random + handcrafted
  • Format compliance - Linux line endings, no trailing whitespace

Platform-Specific

  • Polygon - Integrated workflow for teams
  • Codeforces - Requires 5-25 rated contests
  • Luogu - Requires competition awards

Red Flags - STOP

Anti-patternFix
Undefined terms in statementAdd definitions in problem description
Inconsistent terminologyUse same word for same concept
Weak samplesInclude edge cases and wrong interpretations
Incomplete data rangesSpecify ALL variables' ranges
Wrong time limitTest std × 2 minimum
Poor subtask designUse clear structure, avoid percentages

Essential Code

testlib Generator

#include "testlib.h"
int main(int argc, char* argv[]) {
    registerGen(argc, argv, 1);
    int n = opt<int>("n");
    vector<int> a(n);
    for (int i = 0; i < n; i++)
        a[i] = rnd.next(1, 1000000);
    println(n);
    println(a);
}

Basic Checker

#include "testlib.h"
int main(int argc, char* argv[]) {
    registerTestlibCmd(argc, argv);
    int jans = ans.readInt();
    int pans = ouf.readInt();
    if (pans == jans) quitf(_ok, "%d", pans);
    else quitf(_wa, "expected %d, found %d", jans, pans);
}

References

Source Transparency

This detail page is rendered from real SKILL.md content. Trust labels are metadata-based hints, not a safety guarantee.

Related Skills

Related by shared tags or category signals.

Coding

tailwindcss-design

No summary provided by upstream source.

Repository SourceNeeds Review
Coding

flutter-design

No summary provided by upstream source.

Repository SourceNeeds Review
Coding

web-design-mastery

No summary provided by upstream source.

Repository SourceNeeds Review
Coding

mobile-app-design-mastery

No summary provided by upstream source.

Repository SourceNeeds Review