Your task is to write a function for calculating the score of a 10 pin bowling game. The input for the function is a list of pins knocked down per roll for one player. Output is the player's total score.
A game consists of 10 frames. In each frame the player rolls 1 or 2 balls, except for the 10th frame, where the player rolls 2 or 3 balls. The total score is the sum of your scores for the 10 frames
- If you knock down fewer than 10 pins with 2 balls, your frame score is the number of pins knocked down