This is a very simple yet very interesting program in python.
We are going to make our text, word or string UPSIDE DOWN which will be still readable on phone or desktop if you stand on your head lol.
But any ways... lets do a little research first.
I am going to collect upside down texts using google as it cannot be written by yourself and if you do it would be time consuming.
To make this quick here are some text that I have found from following sources:
https://www.sololearn.com/Discuss/1683898/upside-down-text-is-ʇɥǝɹǝ-ɐu-ndsᴉpǝ-poʍu-ɟnuɔʇᴉou
#############UPSIDE DOWN TEXT###############
Small letters: - zʎxʍʌnʇsɹbdouɯןʞſ̣ᴉɥɓɟǝpɔqɐ Capital letters: - Z⅄XMꓥꓵꓕSꓤÒꓒONꟽ⅂ꓘᒋIΗ⅁ℲƎꓷↃꓭꓯ Digits: - 68ㄥ9૬ҺƐᘔƖ0
########################################
&
for punctuation what we would import string and type string.punctuation and paste the output in https://www.upsidedowntext.com
i.e.
>>> import string >>> string.punctuation '!"#$%&\'()*+,-./:;<=>?@[\\]^_`{|}~'
#############UPSIDE DOWN TEXT###############
punctuation: - ~{|},‾^[\\]@¿<=>;:/˙-'+*(),\⅋%$#¡
Now, next step we are going to assign all small, capital, digits and punctuation text to our regular text and create a directory list. Obviously that does not mean we are going to type everything manually else it will be 2022 happy new year bye bye lol
So to do it really quick follow this code:
# For lower Case import string txt = "zʎxʍʌnʇsɹbdouɯןʞſᴉɥɓɟǝpɔqɐ" txt = txt[::-1] text = string.ascii_lowercase for i in range(1,len(txt)): print("'"+text[i]+"':'"+txt[i]+"',")
# For Upper Case import string txt = "Z⅄XMꓥꓵꓕSꓤÒꓒONꟽ⅂ꓘᒋIΗ⅁ℲƎꓷↃꓭꓯ" txt = txt[::-1] text = string.ascii_uppercase for i in range(0,len(txt)): print("'"+text[i]+"':'"+txt[i]+"',")
# For Digits import string txt = "68ㄥ9૬ҺƐᘔƖ0" txt = txt[::-1] text = string.digits for i in range(0,len(txt)): print("'"+text[i]+"':'"+txt[i]+"',")
# For Punctuation import string txt = "~{|},‾^[/]@¿<=>;:\˙-'+*(),⅋%$#X¡" txt = txt[::-1] text = string.punctuation for i in range(0,len(txt)): print("'"+text[i]+"':'"+txt[i].replace("X",",,")+"',")
'a':'ɐ','b':'q','c':'ɔ','d':'p', 'e':'ǝ','f':'ɟ','g':'ɓ','h':'ɥ', 'i':'ᴉ','j':'ſ','k':'ʞ','l':'ן', 'm':'ɯ','n':'u','o':'o','p':'d', 'q':'b','r':'ɹ','s':'s','t':'ʇ', 'u':'n','v':'ʌ','w':'ʍ','x':'x', 'y':'ʎ','z':'z', 'A':'ꓯ','B':'ꓭ','C':'Ↄ','D':'ꓷ', 'E':'Ǝ','F':'Ⅎ','G':'⅁','H':'Η', 'I':'I','J':'ᒋ','K':'ꓘ','L':'⅂', 'M':'W','N':'N','O':'O','P':'ꓒ', 'Q':'Ò','R':'ꓤ','S':'S','T':'ꓕ', 'U':'ꓵ','V':'ꓥ','W':'M','X':'X', 'Y':'⅄','Z':'Z', '0':'0','1':'Ɩ','2':'ᘔ','3':'Ɛ', '4':'Һ','5':'૬','6':'9','7':'ㄥ', '8':'8','9':'6', '!':'¡','"':',,','#':'#','$':'$', '%':'%','&':'⅋','`':',','(':')', ')':'(','*':'*','+':'+',',':'"', '-':'-','.':'˙','/':'\\',':':':', ';':';','<':'>','=':'=','>':'<', '?':'¿','@':'@','[':']','\\':'/', ']':'[','^':'^','_':'‾','`':',', '{':'}','|':'|','}':'{','~':'~', ' ':' ',
Now we will assign the following data directory into our Upside down text Generator Python Script.
[Here is the complete code]
UPSIDE DOWN TEXT GENERATOR SCRIPT IN PYTHON
# Upside Down Text Generator def upside(instring): upside_dict = { 'a':'ɐ','b':'q','c':'ɔ','d':'p', 'e':'ǝ','f':'ɟ','g':'ɓ','h':'ɥ', 'i':'ᴉ','j':'ſ','k':'ʞ','l':'ן', 'm':'ɯ','n':'u','o':'o','p':'d', 'q':'b','r':'ɹ','s':'s','t':'ʇ', 'u':'n','v':'ʌ','w':'ʍ','x':'x', 'y':'ʎ','z':'z', 'A':'ꓯ','B':'ꓭ','C':'Ↄ','D':'ꓷ', 'E':'Ǝ','F':'Ⅎ','G':'⅁','H':'Η', 'I':'I','J':'ᒋ','K':'ꓘ','L':'⅂', 'M':'W','N':'N','O':'O','P':'ꓒ', 'Q':'Ò','R':'ꓤ','S':'S','T':'ꓕ', 'U':'ꓵ','V':'ꓥ','W':'M','X':'X', 'Y':'⅄','Z':'Z', '0':'0','1':'Ɩ','2':'ᘔ','3':'Ɛ', '4':'Һ','5':'૬','6':'9','7':'ㄥ', '8':'8','9':'6', '!':'¡','"':',,','#':'#','$':'$', '%':'%','&':'⅋','`':',','(':')', ')':'(','*':'*','+':'+',',':'"', '-':'-','.':'˙','/':'\\',':':':', ';':';','<':'>','=':'=','>':'<', '?':'¿','@':'@','[':']','\\':'/', ']':'[','^':'^','_':'‾','`':',', '{':'}','|':'|','}':'{','~':'~', ' ':' ', } # If there is an unknown character it will indicate with a star * return ''.join([(upside_dict[char] if char in upside_dict else '*') for char in instring[::-1]]) print(upside("YOUR TEXT HERE"))
And the results are Beautiful
>>> upside("Hello world") 'pןɹoʍ oןןǝΗ' >>> upside("I Code In python Just 4 Fun") 'unℲ Һ ʇsnᒋ uoɥʇʎd uI ǝpoↃ I' >>> upside("Note:- TURN ME UPSIDE DOWN TO READ OR STAND ON YOUR HEAD HEHE") 'ƎΗƎΗ ꓷꓯƎΗ ꓤꓵO⅄ NO ꓷNꓯꓕS ꓤO ꓷꓯƎꓤ Oꓕ NMOꓷ ƎꓷISꓒꓵ ƎW Nꓤꓵꓕ -:ǝʇoN' >>>
>>> upside("Enjoy!!!") '¡¡¡ʎoſuƎ'
Comments
Post a Comment