Docker-in-Docker (DinD) capabilities of public runners deactivated. More info

range.ml 189 Bytes
Newer Older
1 2 3 4 5 6 7 8 9 10 11
type t = int * int

let find_map (lo, hi) ~f =
  let rec loop i =
    if i = hi then None
    else
      match f i with
      | None -> loop (i + 1)
      | Some y -> Some y
  in
  loop lo