csci2041/repo-zhan4854/Hwk_07/intVector.ml
Michael Zhang 399845160c
f
2018-01-29 17:35:31 -06:00

11 lines
234 B
OCaml

open Vector
module Int_arithmetic: (Arithmetic with type t = int) = struct
type t = int
let zero = 0
let add x y = x + y
let mul x y = x * y
let str x = string_of_int x
end
module Int_vector = Make_vector (Int_arithmetic)