Recent snippets

Popular snippets

  • Top-Down-Operator-Precedence Parser

    F# implementation of a generic Top-Down-Operator-Precedence Parser as described in this paper http://portal.acm.org/citation.cfm?id=512931 Example starts at line ~300

    89 people like this

    Posted: 14 years ago by fholm

  • Break sequence into n-element subsequences

    I'm working on parallel computations and I thought it would be useful to break work into chunks, especially when processing each element asynchronously is too expensive. The neat thing is that this function is general even though motivation for it is specific. Another neat thing is that this is true lazy sequence unlike what you'd get if you used Seq.groupBy. There are three versions for your enjoyment.

    73 people like this

    Posted: 14 years ago by Dmitri Pavlenkov

  • Projecting lists

    Three functions showing how to implement projection for functional lists. First version uses naive recursion and the second one is tail-recursive using the accumulator parameter. The third version extends this with continuation passing.

    74 people like this

    Posted: 15 years ago by Tomas Petricek

Snippets by tags

parsing (28) math (35) mailboxprocessor (27) collections (16) algorithms (26) lists (15) monad (24) sequences (48) reflection (19) sequence (32) seq (54) fold (22) html (16) design patterns (18) http (18) string (29) tutorial (17) dsl (23) computation builder (17) tryfsharp (48)

View all...

Database contains 3206 snippets out of which 1719 is public.