Skip to content

Instantly share code, notes, and snippets.

@henrik-ch
Created June 22, 2011 15:43
Show Gist options
  • Save henrik-ch/1040377 to your computer and use it in GitHub Desktop.
Save henrik-ch/1040377 to your computer and use it in GitHub Desktop.
start to generate series of random numbers (tuples of double and millisecond delay)
let random = new System.Random()
Seq.initInfinite (fun _ -> (random.NextDouble(), random.Next(500, 10000)))
|> Seq.filter (fun (x,y) -> x < 0.5)
|> Seq.take 5
|> Seq.iter (fun elem -> printfn "%A" elem)
printfn ""
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment