My Quest to find the Among us code & character:
While I was doomscrolling on Instagram a while back, I saw a weird programming post, claiming that you could use a Python one-liner to display the well-known outline of the character from “Among us”.
Among us gained popularity during the lockdowns of the COVID-19 pandemic, probably due to its relatively simple mechanics and multiplayer mode.
This is what the little guy looks like (thanks to Yazza for the CC licensed art):
The Code
Anyway, I never found the post with the python code again, and a quick internet search did not help either.
This is, why I am writing this: May the next poor soul, trying to find the one-liner, be so lucky to stumble on this post!
chr(sum(range(ord(min(str(not()))))))
This is it. In all of its magnificence, nothing more is required to get this character: ‘ඞ’
The Character ‘ඞ’
‘ඞ’ seems to come from the Sinhalese script, according to Wiktionary.
Sinhala is the language spoken by the majority ethnic group on Sri Lanka.
As a computer science student, I was also interested in the encoding, which is 0x0D9E
.
This brings me back to the python code: What does it do?
What does the Python code do?
We will start analyzing the innermost function, going outside step by step:
not()
returns the boolean valueTrue
str()
turns the booleanTrue
into a string'True'
min()
gets the smallest element of the string, which is the character'T'
ord()
turns the character into its corresponding Unicode number:84
range()
gets us the sequence of numbers from zero to eighty-four: ${0,1,2,…,83,84}$sum()
adds all the numbers of the sequence:3486
or0xD9E
, as we discovered before.chr()
turns the number back into a Unicode character:'ඞ'
So this isn’t really too crazy, it just looks that way! There was probably someone who found the ‘ඞ’ character and just tried to find a crazy way to get to it in python…
Sources
- Picture: https://www.newgrounds.com/art/view/yazza/green-among-us-character
- Character Entry on Wiktionary: https://en.wiktionary.org/wiki/%E0%B6%9E
- Sinhala language on Wikipedia: https://en.wikipedia.org/wiki/Sinhala_language