diff --git a/codewars/ocaml/sum-of-positive/main.ml b/codewars/ocaml/sum-of-positive/main.ml new file mode 100644 index 0000000..fc980ec --- /dev/null +++ b/codewars/ocaml/sum-of-positive/main.ml @@ -0,0 +1,2 @@ +let positive_sum ls = + List.fold_left ( + ) 0 (List.filter (fun x -> x > 0) ls);;