I carry a lot more than this, but specifically for flat tires:
1. Tire levers. Pedro's are cheap and more durable than a lot of them.
2. Patch kit. The park tool vulcanizing one is a good starter, but I was getting enough flats that I broke down and get a bulk set of patches.
3. A spare tube.
4. A pump. I prefer this over CO2. It's cheaper long term and not that much slower. Ideally get one with a gauge.
If it's a nice day and I have time, I'll try and find the leak in the existing tube. Often you can't without submerging in water. If it's bad weather, at night, or I'm in a hurry, I'll swap in the good tube and patch the other one at home. The patched tube becomes my new spare. Tubes can be patched many times over.
It's worth practicing this at home. Your first couple times it will take a while, especially reseating the tire and tube. If your hands aren't very strong, or the tire is a very tight fit with your rim, a tire bead jack may be necessary.
Plenty of good videos, but I liked this one:
http://www.youtube.com/watch?v=3_MCVGd5C2Q