Description
"""
This function returns the associated ‘scientific’ name. Input is the common names.
I am trying create a condition in this function. Function will output the all the keys
in the host_keywords dictionary if the input is not one of the common word or NULL.
"""
def get_keywords(word):
obama = "Obama"
trump = "Trump"
bernie = "Bernie"
biden = "Biden"
keywords = {
"Obamaaa" : obama,
"B.Obama" : obama,
"B.H.O" : obama,
"donald" : trump,
"d.j.trump" : trump,
"joe" : biden,
"j.biden" : biden
}
if word != keywords.keys:
return keywords.keys
else:
return keywords[word]
print(get_keywords('BBB'))
Unformatted Attachment Preview
