Advertisement
HBSB

2.15 if then else

Jan 1st, 2020
135
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Python 0.27 KB | None | 0 0
  1. phrase = input ("Talk to me >")
  2. if phrase == "hi":
  3.   print("hello")
  4. else:
  5.   print("sorry I dont understand this")
  6. print("bye")  
  7.  
  8.  
  9. phrase = input ("Talk to me >")
  10. if phrase == "hi":
  11.   print ("hello")
  12. else:
  13.   print ("Sorry I don't understand this")
  14. print ("Bye")
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement