Skip to content

Instantly share code, notes, and snippets.

@deque-blog
Last active June 16, 2017 13:35
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 deque-blog/09f2b4b7822b7ab7e53b5bdad7ef9290 to your computer and use it in GitHub Desktop.
Save deque-blog/09f2b4b7822b7ab7e53b5bdad7ef9290 to your computer and use it in GitHub Desktop.
FrameCount : Nat
FrameCount = 10
data BowlingGame : Type where
MkBowlingGame : -- Create a bowling game from:
(frames: Vect FrameCount Frame) -- A vector of 10 frames
-> (bonuses : BonusRollType (last frames)) -- The bonus rolls of the last frame
-> {auto prf: ValidBonuses bonuses} -- The bonus rolls precondition
-> BowlingGame
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment