All problems
ASCII Value of a Character
easyPythonStrings
A museum exhibit about early computing shows visitors that text is really stored as numbers. A visitor presses one key and the display shows the number the machine actually holds for that character. Every character has an agreed number, called its code point: the table used for ordinary English letters and digits is the old ASCII table, in which capital A sits at 65.
Task: Read one character and print the number that stands for it.
Input
A single line holding exactly one character. It may be a capital letter, a lower-case letter, or a digit.
Output
One line holding a single integer — that character's code point.
Example:
Input:
A
Output:
65
Sign in to solve this problem
Reading problems is free for everyone — solving them (Run, Submit, and tracking what you've solved) needs an account.
Sign in