Advertisement
simeonshopov

Coffee

Jan 16th, 2020
124
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Python 0.34 KB | None | 0 0
  1. word = input()
  2. words = ['dog', 'cat', 'movie', 'coding']
  3. words_2 = ['DOG', 'CAT', 'MOVIE', 'CODING']
  4. coffee = 0
  5.  
  6. while word != 'END':
  7.     if coffee >= 5:
  8.         print('You need extra sleep')
  9.         break
  10.     if word in words:
  11.         coffee += 1
  12.     if word in words_2:
  13.         coffee += 2
  14.     word = input()
  15. else:
  16.     print(coffee)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement