Untitled
unknown
ocaml
4 years ago
187 B
6
Indexable
let rec inner_pivot list l r =
match list with
[] -> l, r
| x::xs when x < 0 -> inner_pivot xs (x::l) r
| x::xs -> inner_pivot xs l (x::r);;
let pivot l = inner_pivot l [] [];;Editor is loading...