That, and off-by-one errors
0) Cache invalidation
1) Naming things
5) Asynchronous callbacks
2) Off-by-one errors
3) Scope creep
6) Bounds checking
http://people.cs.uchicago.edu/~wiseman/humor/ai-koans.html
Moon instructs a student
One day a student came to Moon and said: “I understand how to make a better garbage collector. We must keep a reference count of the pointers to each cons.”
Moon patiently told the student the following story:
“One day a student came to Moon and said: ‘I understand how to make a better garbage collector...
[Ed. note: Pure reference-count garbage collectors have problems with circular structures that point to themselves.]
FTFY