https://github.com/purplebooth/bowlingkata
I wanted to demo some unit tests in C# for a friend. I did this using the bowling Kata
https://github.com/purplebooth/bowlingkata
Last synced: 10 months ago
JSON representation
I wanted to demo some unit tests in C# for a friend. I did this using the bowling Kata
- Host: GitHub
- URL: https://github.com/purplebooth/bowlingkata
- Owner: PurpleBooth
- Created: 2019-10-06T18:04:04.000Z (almost 7 years ago)
- Default Branch: main
- Last Pushed: 2020-06-09T20:52:34.000Z (about 6 years ago)
- Last Synced: 2025-01-30T10:44:21.502Z (over 1 year ago)
- Language: C#
- Homepage:
- Size: 5.86 KB
- Stars: 0
- Watchers: 3
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# The Bowling Kata
I wanted to demo some unit tests in C# for a friend. I did this using the bowling Kata
## Rules
The the bowling kata is:
Create a class with 2 methods:
- roll(self, pins)
- score(self)
The rules for scoring are as follows
* A game is 10 frames
* Each frame can have up to 2 rolls
* A spare is when you knock down all pins in a frame
* A strike is when you knock down all pins in the first roll of a frame
* The score for a frame is the number of pins knocked down
* If a spare is scored, the next roll is added as a bonus
* If a strike is scored, the next 2 rolls are added as a bonus
* A perfect game is 12 successive strikes and score 300 points