If you just want to convert a string to an integer, it would be:
>>> int(n)
in your case it would be:
>>> m=66
>>> n=int(hex(m))
--
http://mail.python.org/mailman/listinfo/python-list
What OS are you using. I'm not sure about anything else but on a mac
it's:
>>import os
>>os.system("ls -la")
--
http://mail.python.org/mailman/listinfo/python-list
Do you know if there's a way to print a file? I'm trying to print an
HTML file, so your solution is good, but doesn't really work for me.
Just reading the HTML file and the printing the content obviously
wouldn't work. I also tried:
>>> printer.write(file('path/to/file.ext'))
but apparently this
Wow. That worked perfectly. Thanks a lot.
--
http://mail.python.org/mailman/listinfo/python-list
import random
print random.randint(1,20)
#prints random integer from 1 to 20
--
http://mail.python.org/mailman/listinfo/python-list
I just want to print text. I'll try macpython. Thanks for the help.
--
http://mail.python.org/mailman/listinfo/python-list
I just want to print text. I'll try macpython. Thanks for the help.
--
http://mail.python.org/mailman/listinfo/python-list
I can't seem to figure out how to print with my printer using python.
I'm using Mac OSX 10.4. I was thinking maybe something with
applescript. Does anyone know?
--
http://mail.python.org/mailman/listinfo/python-list