Documentation Index
Fetch the complete documentation index at: https://resources.devweekends.com/llms.txt
Use this file to discover all available pages before exploring further.
Contest Day Mastery
The difference between solving 3 problems and 4 problems is rarely skill—it’s strategy, focus, and energy management. This chapter gives you the complete playbook for contest day.Pre-Contest Routine (2 Hours Before)
The Warm-Up Protocol
Pre-Contest Checklist
Physical Preparation (2 hours before)
- Light meal (avoid heavy food—blood goes to digestion, not brain)
- Hydrate well (dehydration = slower thinking)
- 10 minutes of light movement (walk, stretch)
- Bathroom break (nothing worse than urgency during problem D)
Technical Setup (1 hour before)
- Open your template in VS Code
- Test compile: make sure everything works
- Open Codeforces/contest page
- Clear browser cache if needed
- Close ALL other tabs and apps
- Phone on silent, face down
Mental Preparation (30 minutes before)
- Solve 2 easy warm-up problems
- Review your cheat sheet / templates
- Take 3 deep breaths
- Positive self-talk: “I’ve prepared. I’ll do my best.”
Live Contest Strategy
The First 5 Minutes
Time Allocation Strategy
| Rating Target | Problem A | Problem B | Problem C | Problem D | Problem E |
|---|---|---|---|---|---|
| Specialist (1400) | 10 min | 20 min | 40 min | 50 min | - |
| Expert (1600) | 8 min | 15 min | 30 min | 40 min | 27 min |
| Candidate Master | 5 min | 10 min | 20 min | 35 min | 40 min |
Problem Selection During Contest
Adaptive Strategy
When Stuck on C
- Read problem D and E
- Sometimes D is easier than C for YOUR skill set
- Getting D before C is perfectly valid
- Don’t let problem order limit you
When Everything Seems Hard
- Take 30 seconds, close eyes, breathe
- Go back to the easiest unsolved problem
- Simplify: solve for n=1, n=2, n=3
- Sometimes panic blinds you to simple solutions
Time Management Tactics
The Pomodoro for CP
When to Submit vs When to Test More
The Last 10 Minutes
Dealing with WA During Contest
The WA Response Protocol
Check the Obvious (30 seconds)
- Integer overflow?
- Array bounds?
- Wrong data type (int vs long long)?
- Output format (newline at end)?
Trace Sample Case (1 minute)
- Does your code produce correct output for samples?
- If not, debug with samples first
- If yes, your logic might be wrong on edge cases
Generate Edge Cases (2 minutes)
- n = 1 (minimum size)
- All same elements
- All different elements
- Maximum values
- Sorted / reverse sorted input
Common WA Causes (Quick Checklist)
Energy & Focus Management
The Focus Curve
Micro-Recovery Techniques
The 20-20-20 Rule
Box Breathing
Shoulder Rolls
Water Sips
Post-Contest Protocol
Immediate Post-Contest (First 30 minutes)
Quick Reflection (10 minutes)
- What went well?
- What could be better?
- Any patterns in my mistakes?
Upsolving Schedule
The Mistake Journal Entry
After each contest, fill this template:Contest Day Mental Game
Pre-Contest Affirmations
Read these before every contest:During Contest Self-Talk
When Stuck
When Behind
After WA
When Tired
Virtual Contest Protocol
Making Virtuals Count
Virtual Contest Rules
Ideal Virtual Contest Schedule
| Day | Activity |
|---|---|
| Monday | Virtual contest (old Div2) |
| Tuesday | Upsolve virtual + practice |
| Wednesday | Practice weak topics |
| Thursday | Virtual contest (old Div2) |
| Friday | Upsolve + review |
| Saturday | RATED contest (if available) |
| Sunday | Rest / light practice |
Contest Day Checklist Summary
Print this and keep it by your desk:Interview Deep-Dive
You are 45 minutes into a 2-hour contest. You have solved A and B, but you are stuck on C with no clear approach. Problem D looks potentially easier. What is your decision framework?
You are 45 minutes into a 2-hour contest. You have solved A and B, but you are stuck on C with no clear approach. Problem D looks potentially easier. What is your decision framework?
- I apply the 20-minute rule: if I have spent 20 minutes on C with zero progress (not even a partial approach), I must read D. Sunk cost fallacy is the number one time-waster in contests. Problems are not always ordered by difficulty for every contestant — D might use a technique I know well while C tests a pattern I have never seen.
- I spend exactly 2 minutes scanning D: read constraints, identify the problem type, check if I see an approach. If D clicks immediately, I switch fully to D. If D also looks hard, I return to C with fresh eyes — sometimes the mental break of reading a different problem unlocks the insight.
- Time budget at the 45-minute mark with A and B solved: I have 75 minutes left. Ideally, C should take 30-40 minutes and D should take 30-40 minutes. If I have already spent 20 minutes on C with no progress, spending another 20 is unlikely to help. Better to invest 30 minutes in D (where I might make progress) and return to C in the last 20 minutes.
- The meta-principle: maximize expected problems solved, not time spent on any single problem. Solving D and not C is the same score as solving C and not D. Flexibility in problem ordering is a competitive advantage.
Describe your ideal warm-up routine before a rated contest. What specifically do you do, and why does each step matter?
Describe your ideal warm-up routine before a rated contest. What specifically do you do, and why does each step matter?
- 30 minutes before: solve 2-3 problems rated 800-1000 from random tags. This activates problem-solving neural pathways — the same way athletes warm up muscles before competition. I choose familiar topics so the warm-up builds confidence rather than creating anxiety.
- 15 minutes before: review my “Never Again” list (top 5 most common bugs) and my pre-submit checklist. This primes my error-detection circuits. I also open my template, verify it compiles, and have input.txt ready.
- 5 minutes before: close all tabs except the contest page, put phone on silent, and take 3 deep breaths. Physical state matters — I ensure I have water, a clear desk, and no pending distractions.
- Why each step matters: the warm-up problems activate speed and pattern recognition. The checklist review reduces first-submission errors (each WA costs 10 minutes penalty in ICPC scoring). The environmental setup eliminates context-switching, which costs 15-20 minutes of cognitive recovery each time it happens during a contest.
- What NOT to do: solve a hard problem right before the contest (creates frustration), eat a heavy meal (diverts blood from brain to digestion), or read social media (fragments attention).
After a contest where you solved only 2 out of 6 problems and lost 50 rating points, walk me through your post-contest analysis process.
After a contest where you solved only 2 out of 6 problems and lost 50 rating points, walk me through your post-contest analysis process.
- Step 1 (5 minutes): Cool down. I do not analyze while emotional. I stand up, walk around, drink water. Frustration clouds judgment and turns analysis into self-criticism.
- Step 2 (15 minutes): Classify each unsolved problem. For problems C, D, E, F: did I attempt it? If yes, where did I get stuck — wrong approach, correct approach but implementation bug, or ran out of time? If I did not attempt it, was it because I never read it or because I read it and saw no path?
- Step 3 (30 minutes): Read editorials for C and D only (the problems I should have solved at my level). Understand the key insight I missed. Was it a technique I have never seen (knowledge gap) or a technique I know but failed to recognize (pattern recognition gap)?
- Step 4 (next day): Implement the editorial solutions for C and D from scratch. This converts understanding into skill.
- Step 5 (1 week later): Re-solve C and D from scratch without references. If I can solve them cleanly, the lesson stuck. If not, I add them to my spaced repetition queue.
- The rating drop is data, not destiny. I focus on the actionable output: “I need to practice binary search on answer” is actionable. “I am bad at contests” is not.