Skip to content

Commit 5207824

Browse files
authored
Update day2-2.py
1 parent 7c31331 commit 5207824

File tree

1 file changed

+2
-4
lines changed

1 file changed

+2
-4
lines changed

day2-2.py

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
1-
#!/usr/bin/python
1+
#!/usr/local/bin/snek
22
# cat day2input.txt | ./day2-2.py
33
sum = 0
44
s = input()
5-
while True:
5+
while s != '.':
66
opponent = chr(ord(s[0])+ord('X')-ord('A'))
77
if opponent == 'X':
88
correct = 'Y'
@@ -36,6 +36,4 @@
3636
print(score)
3737
sum += shape + score
3838
s = input()
39-
if s == '.':
40-
break
4139
print(sum)

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy