Changeset 3453:0accba41bd9f in livinglogic.python.xist

Show
Ignore:
Timestamp:
07/04/08 15:41:29 (11 years ago)
Author:
Walter Doerwald <walter@…>
Branch:
default
Message:

Add examples for chr() and ord().

Files:
1 modified

Legend:

Unmodified
Added
Removed
  • docs/UL4.rst

    r3452 r3453  
    542542 
    543543``chr(x)`` returns a one-character string with a character with the codepoint 
    544 ``x``. ``x`` must be an integer. 
     544``x``. ``x`` must be an integer. For example ``<?print chr(0x61)?>`` outputs 
     545``a``. 
    545546 
    546547 
     
    549550 
    550551The argument for ``ord`` must be a one-character string. ``ord`` returns the 
    551 codepoint of that character as an integer. 
     552codepoint of that character as an integer. For example ``<?print ord('a')?>`` 
     553outputs ``97``. 
    552554 
    553555