14 lines
358 B
Text
14 lines
358 B
Text
|
#!/usr/bin/env python3
|
||
|
import sys
|
||
|
|
||
|
def flag_emoji(country_code):
|
||
|
offset = 127397
|
||
|
flag = ''.join(chr(ord(char) + offset) for char in country_code.upper())
|
||
|
return flag
|
||
|
|
||
|
if __name__ == "__main__":
|
||
|
if len(sys.argv) > 1:
|
||
|
country_code = sys.argv[1]
|
||
|
print(flag_emoji(country_code))
|
||
|
else:
|
||
|
print("No country code provided")
|