Commits

Christoph Schindler committed a0097a6

pair 6

Comments (0)

Files changed (1)

BowlingWithAVengeance/bowling.py

 
 def parse_roll(roll):
     if roll == '/':
-        return '/'
+        return SPARE
     return STRIKE
     
 def frame_score(frame):
     return sum(frame)
     
+def is_strike(frame):
+    if frame[0]==10:
+        return True
+    return False
+
 def get_score(frames):
     score = 0
-    for frame in frames:
+    
+    for index,frame in enumerate(frames):
         score += frame_score(frame)
     if score == 18:
         return 26