From 5ab4cd7e48036c237ce50c086b56d3f063ea55bf Mon Sep 17 00:00:00 2001 From: Baptiste Date: Mon, 9 Dec 2024 14:42:53 +0100 Subject: [PATCH] feat: arc list --- src/tools.ml | 2 +- src/tools.mli | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/tools.ml b/src/tools.ml index ad9b0e6..57bf0ae 100644 --- a/src/tools.ml +++ b/src/tools.ml @@ -31,4 +31,4 @@ let update_graph graph list value = |(id1,id2)::rest -> let arc = find_arc graph id1 id2 in match arc with | None-> raise Not_found - | Some x -> if x.lbl < acu then take_min graph rest x.lbl else take_min graph rest acu \ No newline at end of file + | Some x -> if x.lbl < acu then take_min graph rest x.lbl else take_min graph rest aculet list_arc graph = e_fold graph (fun acu t -> t::acu) [] \ No newline at end of file diff --git a/src/tools.mli b/src/tools.mli index 7f1c55d..4e39efa 100644 --- a/src/tools.mli +++ b/src/tools.mli @@ -13,4 +13,4 @@ val add_arc: int graph -> id -> id -> int -> int graph raise Not_found if the arc does not exist in the graph *) val update_graph: int graph -> (id*id) list -> int -> int graph -val take_min: int graph -> (id * id) list -> int -> int \ No newline at end of file +val list_arc: int graph -> int arc list \ No newline at end of file