new program example: mean

parent 98680125
module M
use import int.Int
use import int.EuclideanDivision as E
use import int.ComputerDivision
let mean (x:int) (y:int) =
{ 0 <= x <= y }
x + div (y - x) 2
{ result = E.div (x + y) 2 = div (x + y) 2 }
end
module M
use import int.Int
namespace N
type t = {| mutable a: int; mutable b: int |}
end
let foo () =
{}
1;
2
{ result=1 }
end
(**
module TestRef
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment