Tom_Jung

Python102_RandomChoice

Jan 21st, 2019
128
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.16 KB | None | 0 0
  1. def coin_flip():
  2. import random
  3.  
  4. flip = ["Heads", "Tails"]
  5. print("You flipped a coin and the result was ", random.choice(flip))
  6.  
  7. coin_flip()
Advertisement
Add Comment
Please, Sign In to add comment