Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- term = "message" # term we want to search for
- input = input() # read input from user
- words = input.split() # split the sentence into individual words
- if term in words: # see if one of the words in the input is the word we want
- do_stuff() # the final result (what happens when there is the string included in the output)
- else:
- print("The term '" + term + "' has not been included in the input! :( ")
Add Comment
Please, Sign In to add comment