Make a better tweet decoder

This commit is contained in:
Joe S 2021-01-23 15:32:23 -05:00
parent 411c58ac5d
commit 89b8c97671
1 changed files with 13 additions and 0 deletions

View File

@ -0,0 +1,13 @@
tweet = input('Enter abbreviation from tweet:\n')
tweet_dict = {
'LOL': 'LOL = laughing out loud',
'BFN': 'BFN = bye for now',
'FTW': 'FTW = for the win',
'IRL': 'IRL = in real life'
}
try:
print(tweet_dict[tweet.upper()])
except KeyError:
print("Sorry, don't know that one")