On Fri, Sep 25, 2009 at 10:42 PM, Bahadir <span dir="ltr"><<a href="mailto:bilgehan.balban@gmail.com">bilgehan.balban@gmail.com</a>></span> wrote:<br><div class="gmail_quote"><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
Hi there,<br>
<br>
My question is simple, but I've been spending some hours over the web<br>
and still struggling to get this right: How do I format a string that<br>
contains single quotes in it?<br></blockquote><div><br>I don't know what you're doing wrong, but I've tried both Python 2.6.2 and 3.1.1, and the following worked perfectly for me:<br><br>>>> a = "Mrra%d 'Mrraa!!%d'"<br>
>>> a %(1,2)<br>"Mrra1 'Mrraa!!2'"<br><br>Maybe if you share a snippet of the code, or do more actual testing that might help?<br><br>Good luck,<br>Xav <br></div></div>