Snippets tagged yield

  • Random walk

    Create sequence of floating point values generated by random walk process. Functional solution using sequence expressions and yield! construct in a tail-call position.

    38 people like this

    Posted: 9 years ago by Tomas Petricek

  • Generating a tree from a generic type

    I needed a function to generate a tree from a c# class that had some odd semantics, but when I refactored it, I realised almost everyone must have something similar knocking around their codebase, so here's mine.

    0 people like this

    Posted: 6 years ago by Sean Newham