summaryrefslogtreecommitdiff
path: root/tips.md
blob: 2ad40be60eed370c6949730ede795e9f9faeeb8b (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
## Starting
 
 - Look for unusual conditions!
 
 - Consider bounds, but not too much
 
 - Do the sample cases!
 
 - Write stuff down!
 

## Stuck
 
 - Do something instead of nothing!

 - Stay organized
 
 - Make more test cases!
 
 - Consider simpler cases
 
 - Rephrase conditions
 
 - Don't be afraid of casework
 
 - Work backwords and think about what the solution looks like
 
 - Start over from a different direction!
 
 - Write a slower algorithm
 
 - Construct a new graph or tree, or express a tree as an array
 
 - Try a geometric transformation
 
 - Find an invariant
 
 - Try to force a known algorithm to work
 

## Submitting
 
 - Consider corner cases
 
 - Watch out for overflow and bounds!

 - Make sure you clear stuff between test cases