the print statement

2006-05-06 Thread mirandacascade
e y a signal that what follows is a hex value? 2) is it more than just a coincidence that 146 (the result of ord(y[3])) is the decimal equivalent of the hex number 92? 3) is there any character set in which 146 represents the single-quote/apostrophe character? if so, which character set? 4) what i

Re: the print statement

2006-05-06 Thread Ben Finney
[EMAIL PROTECTED] writes: > My questions are: Mostly answered in the language reference: http://docs.python.org/ref/strings.html> -- \ "Facts are meaningless. You could use facts to prove anything | `\ that's even remotely true!" -- Homer, _The Simpsons_ | _o__)

Re: the print statement

2006-05-06 Thread Tim Roberts
our VGA font happens to display "left single quote" and "right single quote" with the same glyph as "apostrophe". >4) what is the role/function of the backslash character in the variable >y? See above. \x introduces a hex character. \047 is another special sequ

Re: the print statement

2006-05-06 Thread mirandacascade
Thank you. Yes, that post answers most of the questions. I now have a bit of an understanding of the \xhh pattern. It's still unclear to me, however, how one can go from the \x92 pattern and arrive at the apostrophe character. Is \x92 theh apostrophe character in another character set? If so,

Re: the print statement

2006-05-06 Thread Terry Reedy
<[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > bit of an understanding of the \xhh pattern. It's still unclear to me, > however, how one can go from the \x92 pattern and arrive at the > apostrophe character. Is \x92 the apostrophe character in another > character set? If so, whi

Re: the print statement

2006-05-07 Thread Kent Johnson
[EMAIL PROTECTED] wrote: > Thank you. Yes, that post answers most of the questions. I now have a > bit of an understanding of the \xhh pattern. It's still unclear to me, > however, how one can go from the \x92 pattern and arrive at the > apostrophe character. Is \x92 theh apostrophe character i

Re: the print statement

2006-05-08 Thread Tim Roberts
Dennis Lee Bieber <[EMAIL PROTECTED]> wrote: >On Sun, 07 May 2006 00:09:06 GMT, Tim Roberts <[EMAIL PROTECTED]> declaimed >the following in comp.lang.python: > >> [EMAIL PROTECTED] wrote: >> >> >6) Would it be correct to infer that the print statement

Q: The `print' statement over Unicode

2005-05-04 Thread François Pinard
icode string (containing a non-ASCII character) as an argument to the `print' statement, and I did _not_ get an error. This is rather surprising to me. I reread the section of the Python reference manual (version 2.3.4, this machine uses 2.3.3 currently), and it does not say anything about

Re: Q: The `print' statement over Unicode

2005-05-04 Thread Thomas Heller
t; > However, this morning, I mistakenly forgot to do so before using one > Unicode string (containing a non-ASCII character) as an argument to > the `print' statement, and I did _not_ get an error. This is rather > surprising to me. I reread the section of the Python reference ma

Re: Q: The `print' statement over Unicode

2005-05-07 Thread François Pinard
code string. Much thanks for this information. I was not aware of this file attribute. Looking around, I found a quick description in the Library Reference, under "2.3.8 File Objects". However, I did not find in the documentation the rules stating how or when this attribute receives a

Re: Q: The `print' statement over Unicode

2005-05-07 Thread "Martin v. Löwis"
François Pinard wrote: > Am I looking in the wrong places, or else, should not the standard > documentation more handily explain such things? It should, but, alas, it doesn't. Contributions are welcome. The algorithm to set sys.std{in,out}.encoding is in sysmodule.c:_PySys_Init and pythonrun.c:Py

Re: Q: The `print' statement over Unicode

2005-05-07 Thread François Pinard
[Martin von Löwis] > François Pinard wrote: > > > Am I looking in the wrong places, or else, should not the standard > > documentation more handily explain such things? > It should, but, alas, it doesn't. Contributions are welcome. My contributions are not that welcome. If they were, the core t

Re: Q: The `print' statement over Unicode

2005-05-07 Thread "Martin v. Löwis"
François Pinard wrote: > My contributions are not that welcome. If they were, the core team > would not try forcing me into using robots and bug trackers! :-) Ok, then we need to wait for somebody else to contribute a documentation patch. > Thanks. Your kind explanation, above, should make it,

Re: Q: The `print' statement over Unicode

2005-05-07 Thread Jeremy Bowers
On Sat, 07 May 2005 12:10:46 -0400, FranÃois Pinard wrote: > [Martin von LÃwis] > >> FranÃois Pinard wrote: >> >> > Am I looking in the wrong places, or else, should not the standard >> > documentation more handily explain such things? > >> It should, but, alas, it doesn't. Contributions are wel

Re: Q: The `print' statement over Unicode

2005-05-08 Thread John J. Lee
Jeremy Bowers <[EMAIL PROTECTED]> writes: > On Sat, 07 May 2005 12:10:46 -0400, François Pinard wrote: > > > [Martin von Löwis] > > > >> François Pinard wrote: > >> > >> > Am I looking in the wrong places, or else, should not the standard > >> > documentation more handily explain such things? >

Re: Q: The `print' statement over Unicode

2005-05-08 Thread Jeremy Bowers
On Sun, 08 May 2005 13:46:22 +, John J. Lee wrote: > I don't mean to put words into FranÃois' mouth, but IIRC he managed, > for example, GNU tar for some time and, while using some kind of > tracking system "under the covers", didn't impose it on his users. > > IMVHO, that was very nice of him

Re: Q: The `print' statement over Unicode

2005-05-08 Thread "Martin v. Löwis"
Jeremy Bowers wrote: > Then I'd honor his consistency of belief, but still consider it impolite > in general, as asking someone to do tons of work overall to save you a bit > is almost always impolite. This is not what he did, though - he did not break "the protocol" by sending in patches by email