Bug in the documentation (?)

P

Pawel Oleksik

Hi, Snake Tamers

According to http://www.python.org/doc/2.4.1/lib/typesseq-strings.html (and
next releases):

"""
The conversion types are:

Conversion Meaning Notes
[...]
x Unsigned hexadecimal (lowercase). (2)
X Unsigned hexadecimal (uppercase). (2)

"""


But actually:

Python 2.4.1 (#1, Apr 10 2005, 22:30:36)
[GCC 3.3.5] on linux2
Type "help", "copyright", "credits" or "license" for more information.'-1e240'

so it is a _signed_ hexadecimal.
However, sometimes it would be convinient to get the unisgned conversion
(especially, since id(..) can return a negative value).
This way is rather clumsy:
'b7b75380'

Do you see any better solution?

p.o.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,744
Messages
2,569,482
Members
44,901
Latest member
Noble71S45

Latest Threads

Top