Reputation:
Simple question, i have an integer and a float. How do i find the sum of these.
I get an error saying
"the type float did not match the type int"
let add x y = x + (float y)
let m = sum 2.3 2
do printfn "%A" l
Upvotes: 1
Views: 94
Reputation: 2459
You can use the function add
you have defined. I suppose that's what you meant to call, instead of sum
in your second line.
Upvotes: 3