coverting numbers to strings

emile at fenx.com emile at fenx.com
Sat May 27 20:16:06 EDT 2000


I'm not sure what's going on, but your post is littered with
what looks to be hex representation of high order ascii
characters.  What you may be asking for is the chr() function.

>>> print chr(65)
A
>>> print ord('A')
65

HTH,

BTW, does anyone know if these characters are being generated
on my end or on the sending end?

Emile van Sebille
emile at fenx.com



Z 3 Penguin <z3penguin at penguinpowered.com> wrote in message
news:<8gpnqb$ki7$1 at bob.news.rcn.net>...
> i want to convert an integer to a string contaning the bytes for that value,
> i.e
> 
> +AD4- a+AD0-300
> +AD4- b+AD0- func(a)
> +AD4- for i in len(b):
> ...    print ord(b+AFs-i+AF0-)
> ...
> 1
> 44
> +AD4-
> 
> 
> --
> -----
> Z 3 Penguin
> z3p+AEA-z3penguin.org
> 
>   ()
>   (o+AF8-
>   //+AFw-
> +ADw--+AFwAXw-/
> 
> This is a virus that works on the honor system.  Send this .sig to everyone
> in your address book and randomly delete some of your files.
> 
> -- 
> http://www.python.org/mailman/listinfo/python-list
>




More information about the Python-list mailing list