-
Notifications
You must be signed in to change notification settings - Fork 181
/
Copy pathrock,paper,scissor.py
49 lines (47 loc) · 2.22 KB
/
rock,paper,scissor.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
import random
while 2 == 2:
print('--------------------------------------------------------------')
get_again = raw_input('Enter rock paper or scissor : ')
make_use = random.choice(['rock','paper','scissor'])
print('--------------------------------------------------------------')
print(make_use)
print('--------------------------------------------------------------')
if get_again == 'rock' and make_use == 'paper':
print('computer wins! You "LOSE" ')
print('--------------------------------------------------------------')
continue
elif get_again == 'rock' and make_use == 'scissor':
print('computer loses You win!')
print('--------------------------------------------------------------')
break
elif get_again == 'rock' and make_use == 'rock':
print('It\'s a tie ! try again !')
print('--------------------------------------------------------------')
continue
elif get_again == 'paper' and make_use == 'paper':
print('It\'s a tie ! try again !')
print('--------------------------------------------------------------')
continue
elif get_again == 'scissor' and make_use == 'scissor':
print('It\'s a tie ! try again !')
print('--------------------------------------------------------------')
continue
elif get_again == 'paper' and make_use == 'scissor':
print('computer wins! You "LOSE" ')
print('--------------------------------------------------------------')
continue
elif get_again == 'scissor' and make_use == 'paper':
print('computer loses You win!')
print('--------------------------------------------------------------')
break
elif get_again == 'paper' and make_use == 'rock':
print('computer wins! You "LOSE" ')
print('--------------------------------------------------------------')
continue
elif get_again == 'scissor' and make_use == 'rock':
print('computer wins You "LOSE" ')
print('--------------------------------------------------------------')
continue
else :
print('Invalid input: Try again')
continue