Syntax
ord(character)
Description
The ord() function returns the ASCII value of a given character.
Example
line="0123456789This is a line" println("Chr Ascii value") println("-----------------") foreach n in line { println(n, " ", ord(n)) } Chr Ascii value ----------------- 0 48 1 49 2 50 3 51 4 52 5 53 6 54 7 55 8 56 9 57 T 84 h 104 i 105 s 115 32 i 105 s 115 32 a 97 32 l 108 i 105 n 110 e 101