Dapatkan kode untuk sebuah karakter
=CODE(text)
| Parameter | Deskripsi |
|---|---|
text |
The text for which you want a numeric code. |
The CODE function returns a numeric code for a given character. For example, CODE("a") returns the code 97:
=CODE("a") // returns 97
With the character "a" in cell A1, the formula below returns the same result:
=CODE(A1) // returns 97
The CODE function takes a single argument, text, which is normally a text value. If text contains more than one character, the CODE function returns a
=CODE("A") // returns 65
=CODE("Apple") // returns 65
The CODE function will handle numeric input for the numbers 0-9:
=CODE(1) // returns 49
To get a character for a given numeric code, you can use the CHAR function:
=CHAR(65) // returns "A"