I want to calculate binom like this:
let t = seq { 1..10 } |> Seq.takeWhile (fun e -> e % 2 == 0)
but the compiler complain
playground.fsx(27,59): error FS0001: The type 'int' does not support the operator '=='
What am I doing wrong?
F# uses single =
for equality operator:
let t = seq { 1..10 } |> Seq.takeWhile (fun e -> e % 2 = 0)
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With