itoa() ?

Alex Martelli aleax at aleax.it
Fri Jan 11 17:41:22 CET 2002


"John W. Baxter" <jwbaxter at spamcop.net> wrote in message
news:110120020817436710%jwbaxter at spamcop.net...
> In article <mailman.1010725875.31778.python-list at python.org>, Jason
> Orendorff <jason at jorendorff.com> wrote (along with others, similarly):
>
> > > Quoting yvan:
> > > I would like to retrieve a character value from its integer ASCII
value.
> > > For example:
> > > 72 would give me the letter H
> >
> > chr(72)
>
> Or, in the proper modern Unicode Spirit,
> >>> unicode(chr(72))
> u'H'

better:

>>> unichr(72)
u'H'


Alex






More information about the Python-list mailing list