Created
April 26, 2017 14:26
-
-
Save infinisil/503a8d670c1fe407c2c19d339ed4eca1 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
ChooseType : (n : Nat) -> (k : Nat) -> {auto ok : LTE k n} -> Type | |
ChooseType n Z {ok=LTEZero} = () | |
ChooseType n@(S ns) (S ks) {ok=(LTESucc oks)} = Fin n -> ChooseType ns ks | |
data Choice : (n : Nat) -> (k : Nat) -> Type where | |
Choose : (n : Nat) -> (k : Nat) -> { auto ok : LTE k n } -> | |
ChooseType n k -> Choice n k | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment