Today we'll be using Python!
pronouncing
pyenchant
better_profanity
import pronouncing
import random
from better_profanity import profanity
def rhyme(rhymingWord):
foundSwear = True
while(foundSwear):
wordChoice = pronouncing.rhymes(rhymingWord)
output = ""
if (len(wordChoice) <= 0):
output = "**FAILURE**"
return output
output = random.choice(wordChoice)
if (not profanity.contains_profanity(output)):
foundSwear = False
return output