Definition belast {T : Type} (s : seq T) :=
match s with
| [::] => [::]
| h :: s => belast h s
end.

Lemma map_pairmap {T T0 T1 : Type} (f : T0 -> T1) (g : T -> T -> T0) (s : seq T) (x0 : T) :
map f (pairmap g x0 s) = pairmap (fun x y => f (g x y)) x0 s.