The backslash is a key to enter especial characters, like breakline: '\n'<br><br>There is two backslashes cause of this especial condition of this char, but if you try print the specific string you will see that only one backslash remain:
<br><br>print alist[2]<br><br><div><span class="gmail_quote">On 3/12/07, <b class="gmail_sendername">Fabio Gomes</b> <<a href="mailto:flgoms@hotmail.com">flgoms@hotmail.com</a>> wrote:</span><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">




<div>
Hi list,<br><br>  I'm trying to use a string with backslashes in a list. But Python parses strings in lists with repr().<br><br><br>>>> alist = ['a', 'b', 'c:\some\path']<br>>>> alist
<br>['a', 'b', 'c:\\some\\path']<br>>>> print alist<br>['a', 'b', 'c:\\some\\path']<br><br><br>  I already tried str() and raw (r) but it didn't work. All I want is to keep a single backslash in the string since it is a path information.
<br><br>  Can anyone help me, please?<br><br>  Thank you.<br><br><hr>O Windows Live Spaces está aqui! Descubra como é fácil criar seu espaço na Web e sua rede amigos. <a href="http://spaces.live.com/signup.aspx" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">
Confira!</a></div>
<br>--<br><a onclick="return top.js.OpenExtLink(window,event,this)" href="http://mail.python.org/mailman/listinfo/python-list" target="_blank">http://mail.python.org/mailman/listinfo/python-list</a><br></blockquote></div>
<br>