Question: 8 points https:/www.reddit.com/r/AVoid5/ (https:/www.reddit.com/r/AVoid50 There is a subreddit in which if the user uses the letter e or E they get banned. Let's pretend you
8 points https:/www.reddit.com/r/AVoid5/ (https:/www.reddit.com/r/AVoid50 There is a subreddit in which if the user uses the letter "e" or "E" they get banned. Let's pretend you have been hired to help new users avoid getting banned. As a subtle reminder that they are using an inappropriate letter you will merely replace the offending letter with the Unicode heart symbol (given to you in the code below). heart-u"u2764" which appears like this when printed: If I wanted to use the heart in a string I could do this heart u"lu2764" my_string "I"+heart+ "bacon!" print(my_string) Ibacon Here's an example of my function in action: remove_fifth_glypth(haha there are some E's in my sentence") haha thr ar som s in my sntnc" 04 0 In I J: def remove_fifth_glypth(input_string): output_string -"" heart = u"\u2764" #Your code goes here return(output_string)
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
