Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- let rec tryFindPathtoAux v t =
- match t with
- | [] -> []:Path
- | t::ts -> tryFindPathto v t @ tryFindPathtoAux v ts:Path
- and tryFindPathto v t:Path =
- match t with
- | N(n,_) when n = v -> [1]:Path
- | N(_,ts) -> List.findIndex (isEqual v) ts::(tryFindPathtoAux v ts);;
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement