writing-statements

Author and translate competitive-programming problem statements in the vnolymp LaTeX template.

1|Updated Sep 3, 2026
One-click install
npx skills add https://github.com/nudetiger/competitive-programming-problem-preparer --skill writing-statements-nudetiger
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: writing-statements
Source: https://github.com/nudetiger/competitive-programming-problem-preparer/tree/main/skills/writing-statements
Command: npx skills add https://github.com/nudetiger/competitive-programming-problem-preparer --skill writing-statements-nudetiger

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve? Writing a competitive-programming problem statement that compiles correctly, follows the vnolymp LaTeX house format, and stays consistent with the problem's constraints and sample data is error-prone when done by hand. This Skill produces a statement .tex file and PDF that match the agreed problem.json numbers and the real sample files. ## Core Features & Use Cases - Two-pass authoring: Pass 1 writes everything except examples once problem.json exists; Pass 2 adds \Examples and \Explanation after sample files are generated by the model solution. - vnolymp template compliance: Enforces the house format — bulleted \InputFile/\OutputFile, numeric \Constraints, OI subtasks environment with scores summing to 100, and per-sample explanation items in Vietnamese. - Build verification: Compiles with latexmk -lualatex and TEXINPUTS pointing at the cloned vnolymp repository, treating missing Vietnamese glyphs or wrong subtask totals as failures even when the build exits 0. - Use Case: After shaping a problem and generating its tests, ask for the Vietnamese statement; the Skill writes chiaqua.tex, wires in the sample files with \exmpfile, and verifies the rendered PDF. ## Quick Start Write the Vietnamese vnolymp statement for my problem using the existing problem.json and sample files, then build the PDF.

Frequently Asked Questions about writing-statements

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I write a competitive programming problem statement in LaTeX?

Use the vnolymp template: write the story and task, then bulleted \InputFile and \OutputFile sections, numeric \Constraints, and a subtasks environment for OI problems. Build with latexmk -lualatex and TEXINPUTS pointing at the cloned vnolymp repository.

How do I add sample test cases to a Polygon problem statement?

Generate samples with the model solution and checker like any other test, never hand-compute output. Reference them in the statement with \exmpfile inside \Examples, and add one \item per test case in the \Explanation section.

Does the vnolymp template support Vietnamese statements?

Yes, vnolymp is the Vietnamese statement package for problems prepared on Polygon. Build with LuaLaTeX and verify the PDF has no missing Vietnamese glyphs; a zero exit code alone does not mean the render is correct.

What is the difference between OI and ICPC statement format?

OI statements include a subtasks environment whose scores must sum to the total points, default 100. ICPC statements omit the subtasks environment entirely and present constraints without per-subtask scoring.

Why does my LaTeX statement build succeed but look wrong?

A zero exit code only means compilation finished. Check for missing Vietnamese glyphs, subtask percentages that do not sum to 100, and prose paragraphs inside \InputFile or \OutputFile, which must use itemize bullets instead.