and you find yourself in front of a big plate of cookies,
the cookies have already won.
To put that in the context of quitting smoking, you can't smoke if you don't have any around and don't place your quit in risky situations.
Willpower
The myth of self-control - Vox - Pocket