List.sorted_append: law of bend-mathlib@0.8.1.0 Import: import bend-mathlib@0.8.1.0/list.bend as List Lines 1061-1068 of bend-mathlib@0.8.1.0/list.bend: https://jend.leeeet.dev/read.txt?path=bend-mathlib@0.8.1.0/list.bend&start_line=1061&end_line=1068 import Base import bend-mathlib@0.8.1.0/nat.bend as MNat # Appending two Nat lists sorted by Nat.is_le, with every element of the first <= every element of the second, gives a sorted list. law sorted_append: for xs: List<&2, Nat> for ys: List<&2, Nat> for bnd: @x: Nat -> @y: Nat -> mem(~Nat, ~Nat.is_eq, x, xs) -> mem(~Nat, ~Nat.is_eq, y, ys) -> MNat.le(x, y) for hx: sorted_by(~Nat, ~Nat.is_le, xs) for hy: sorted_by(~Nat, ~Nat.is_le, ys) sorted_by(~Nat, ~Nat.is_le, List.append(&2, Nat, xs, ys)) Uses (9): https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=List https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=List.append https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Nat https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Nat.is_eq https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Nat.is_le https://jend.leeeet.dev/definition.txt?path=bend-mathlib@0.8.1.0/list.bend&name=internal_sorted_append_cons https://jend.leeeet.dev/definition.txt?path=bend-mathlib@0.8.1.0/list.bend&name=mem https://jend.leeeet.dev/definition.txt?path=bend-mathlib@0.8.1.0/list.bend&name=sorted_by https://jend.leeeet.dev/definition.txt?path=bend-mathlib@0.8.1.0/nat.bend&name=le