On 04/02/14 15:01, Peter Otten wrote:
Alan Gauld wrote:
This led me to wonder if there is a way to get unsigned type
behaviour in Python?
I think you have to apply a mask:
-2 & 0xff
254
Ah! obvious when you see it! :-)
And I'm applying masks all over the place but didn't
think of using it here.
Thanks,
--
Alan G
Author of the Learn to Program web site
http://www.alan-g.me.uk/
http://www.flickr.com/photos/alangauldphotos
_______________________________________________
Tutor maillist - Tutor@python.org
To unsubscribe or change subscription options:
https://mail.python.org/mailman/listinfo/tutor