Section Graph.
Variable (A : finType) (B : Type) (f : A -> B).
Set Default Proof Using "Type".
Definition graph_of_fun : list (A*B) := map (fun x => (x, f x)) enum.

Lemma graph_of_fun_functional x y1 y2 :
In (x, y1) graph_of_fun -> In (x, y2) graph_of_fun -> y1 = y2.