RosettaCodeData/Task/Continued-fraction/F-Sharp/continued-fraction-4.fs
2023-07-01 13:44:08 -04:00

3 lines
274 B
FSharp

let ()=let mutable n=0M in (fun ()->n<-n+1M;let b=n+n-1M in b*b)
let ()=let mutable n=true in (fun ()->match n with true->n<-false;3M |_->6M)
cf2S (()) (()) |> Seq.take 10 |> Seq.pairwise |> Seq.iter(fun(n,g)->printfn "%1.14f < π < %1.14f" (min n g) (max n g))