UwU text convertor in Python Last Updated : 07 Aug, 2021 Comments Improve Suggest changes Like Article Like Report UwU is used as an emoticon to demonstrate a reaction to something cute. In this emoticon, the 'U's signify 2 closed eyes and the 'w' signifies the clenched, excited mouth lips. Imagine seeing something cute, like a baby cutely sneezing, the response can be UwU which is pronounced as "ooh-wooh". UwU text is the type of lingo in which the original text has been "UwUfied". UwU text is supposed to be a cuter version of the original text. It is popular with certain online communities, mostly as a fun practice. Examples: Input : The quick brown fox jumps over the lazy dog. Output : The quick bwown fox jumps ovew the wazy dog. Input : Nooo! I was not late to work! Output : Nyooo! I was nyot wate to wowk! Algorithm : Change all the 'R's and 'r's to 'w' and 'W' respectively.Change all the 'L's and 'l's to 'w' and 'W' respectively.If the current character is 'o' or 'O' and the previous character is either 'M', 'm', 'N' or 'n', then add 'y' between the characters.If none of the condition matches for any character then leave that character as it is. Python3 # Function to convert into UwU text def generateUwU(input_text): # the length of the input text length = len(input_text) # variable declaration for the output text output_text = '' # check the cases for every individual character for i in range(length): # initialize the variables current_char = input_text[i] previous_char = '&# 092;&# 048;' # assign the value of previous_char if i > 0: previous_char = input_text[i - 1] # change 'L' and 'R' to 'W' if current_char == 'L' or current_char == 'R': output_text += 'W' # change 'l' and 'r' to 'w' elif current_char == 'l' or current_char == 'r': output_text += 'w' # if the current character is 'o' or 'O' # also check the previous character elif current_char == 'O' or current_char == 'o': if previous_char == 'N' or previous_char == 'n' or previous_char == 'M' or previous_char == 'm': output_text += "yo" else: output_text += current_char # if no case match, write it as it is else: output_text += current_char return output_text # Driver code if __name__=='__main__': input_text1 = "The quick brown fox jumps over the lazy dog." input_text2 = "Nooo ! I was not late to work !" print(generateUwU(input_text1)) print(generateUwU(input_text2)) Output : The quick bwown fox jumps ovew the wazy dog. Nyooo! I was nyot wate to wowk! Comment More infoAdvertise with us Next Article UwU text convertor in Python Y Yash_R Follow Improve Article Tags : Python Python-Miscellaneous Practice Tags : python Similar Reads Convert Text to Speech in Python There are several APIs available to convert text to speech in Python. One of such APIs is the Google Text to Speech API commonly known as the gTTS API. gTTS is a very easy to use tool which converts the text entered, into audio which can be saved as a mp3 file. The gTTS API supports several language 4 min read Python - UwU text convertor GUI using Tkinter Prerequisites :Introduction to tkinter | UwU text convertor Python offers multiple options for developing a GUI (Graphical User Interface). Out of all the GUI methods, Tkinter is the most commonly used method. It is a standard Python interface to the Tk GUI toolkit shipped with Python. Python with T 4 min read Convert emoji into text in Python Converting emoticons or emojis into text in Python can be done using the demoji module. It is used to accurately remove and replace emojis in text strings. To install the demoji module the below command can be used: pip install demoji The demoji module also requires an initial download of data from 1 min read Convert a String to Utf-8 in Python Unicode Transformation Format 8 (UTF-8) is a widely used character encoding that represents each character in a string using variable-length byte sequences. In Python, converting a string to UTF-8 is a common task, and there are several simple methods to achieve this. In this article, we will explor 3 min read Convert Unicode to ASCII in Python Unicode is the universal character set and a standard to support all the world's languages. It contains 140,000+ characters used by 150+ scripts along with various symbols. ASCII on the other hand is a subset of Unicode and the most compatible character set, consisting of 128 letters made of English 2 min read Like