many_years_after wrote:
> Well, people may input from keyboard. They input some Chinese
> characters, then, I want to create a number. The same number will be
> created if they input the same Chinese characters.
assuming you mean "code point" rather than "ASCII code" (ASCII is a
specific encoding that *doesn't* include Chinese characters), "ord" is
what you want:
char = read_from_some_input_device()
code = ord(char)
see:
http://pyref.infogami.com/ord
</F>
--
http://mail.python.org/mailman/listinfo/python-list