Practice
How to Practise Competitive Programming on Your Phone
A phone won't replace a laptop for a long contest, but it's very good for the practice that actually makes you better: small daily problems, reviewing patterns, and testing an idea while it's fresh. Here's how to use the time you already spend on your phone.
What works well on a phone
- Short problems: 20–40 lines in one function, such as arrays, strings, two pointers, prefix sums.
- Re-solving problems you've seen, from memory, to make patterns automatic.
- Writing the brute force first, to check your understanding of a problem.
- Trying an idea quickly, then finishing on a computer if it grows.
Leave long implementation problems (segment trees, heavy simulation) and timed full contests for a keyboard.
A daily routine that fits in 20 minutes
- Read one problem and write the approach as a comment before any code.
- Write the solution and run it on the samples.
- Add two edge cases you think could break it, and run again.
- If it fails, read the verdict and fix it; if it passes, note the pattern in one line.
Consistency beats volume: one problem a day for a month builds more skill than ten on a weekend.
Typing code on a touch keyboard
- Use a code editor with a symbol row, so braces, brackets and operators are one tap away instead of buried in keyboard pages.
- Turn on autocomplete and bracket matching; they save more taps than anything else.
- Use short, clear variable names and helper functions: less typing, fewer typos.
- Pair a Bluetooth keyboard for longer sessions; editors with hardware-keyboard shortcuts feel like a laptop.
Test like a judge would
Running code once with one input tells you little. Add the sample tests and your own edge cases, run them together, and read each verdict. See how to write test cases that catch bugs.
Setting up omni compiler for practice
- Pick from 65 languages, with several versions of the popular ones, so you practise in the language you compete in.
- The symbol row above the keyboard has braces, brackets, arrows, comment toggle and indent.
- Add up to 100 test cases per run and get a verdict for each, with timing and the expected output beside yours.
- Projects are plain folders on your phone, so you can write offline; runs started offline are sent when you reconnect.
- Examples and classic practice problems come with ready-made tests and starter solutions.
When a verdict surprises you, judge verdicts explained lists the usual causes.