Xavier Morel wrote: > You can even do base conversions with it: > >>> a="0xe" > >>> int(a) > Traceback (most recent call last): > File "<pyshell#7>", line 1, in -toplevel- > int(a) > ValueError: invalid literal for int(): 0xe > >>> int(a,16) # Silly me, 0xe is not a decimal > 14 Or even say "look to the text for a clue about the base":
>>> int('0xe', 0) 14 >>> int('010', 0) 8 >>> int('10', 0) 10 -- -Scott David Daniels [EMAIL PROTECTED] -- http://mail.python.org/mailman/listinfo/python-list