Skip to content

Instantly share code, notes, and snippets.

@TheSecretSquad
Created May 2, 2014 23:40
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save TheSecretSquad/c1bc538dc67eb453b413 to your computer and use it in GitHub Desktop.
Save TheSecretSquad/c1bc538dc67eb453b413 to your computer and use it in GitHub Desktop.
Bowling Score Calculator Kata from Daedtech.com Alternative Design Question - http://www.daedtech.com/tdd-for-breaking-problems-apart-3-finishing-up
using System;
using System.Collections.Generic;
using System.Linq;
using Microsoft.VisualStudio.TestTools.UnitTesting;
namespace ScratchPadTest
{
public class BowlingScoreCalculator
{
private Frames _frames = new Frames();
public int Score { get; private set; }
public void BowlFrame(Frame frame)
{
Score += frame.Total(_frames);
_frames.Push(frame);
}
public Frames Frames { get { return _frames; } }
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment