It's just a matter of logic really. Also, sticking that

wouldn't balance the equation at all since we haven't compensated for the carbons and hydrogens!
Notice that there's 7 carbons and 14 hydrogens on the left. We can stick a 7 in front of carbon dioxide to balance the carbons (it's our only source!) and stick a 7 in front of our dihydrogen monoxide (since this is our only source as well).
Now, let's compensate for the oxygens. On the right hand side, we would have 14 oxygens from

and 7 oxygens from

giving us a total of 21 oxygens.
This suggests sticking in

in front of

on the left hand side and we'll be done.
If you don't like fractions, multiply both sides by 2 and you'll get integer values.