Place it at the end of a failed attempt or a lost argument, after the setup has made the outcome clear. Follow it with Nelson's Ha-Ha for a second reaction, or put Damn just before it to build the embarrassment first.