-
-
Save Yardanico/68ac519419d2bd459941e1fe2f7de58e 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
template toSeq(): untyped = | |
block: | |
var result = newSeq[int](1) | |
result | |
proc randomSample*(iter: iterator(): int) = | |
discard | |
proc clItems(s: seq[int]): iterator(): int = | |
(iterator(): int = | |
yield 1 | |
) | |
randomSample(toSeq().clItems) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment