head or tail python

Solutions on MaxInterview for head or tail python by the best coders in the world

showing results for - "head or tail python"
Josefina
03 Nov 2018
1import random
2name = str(input("Who will take head your name:- "))
3name2 = str(input("Who will take tail your name:- "))
4head_or_tail = random.randint(0,1)
5if head_or_tail == 1:
6    print(name,"you won it's Head and",name2,"lost")
7elif head_or_tail == 0:
8    print(name2,"You won it's tail and",name,"you lost")