List.foldr_map_sym: law of bend-mathlib@0.8.1.0 Import: import bend-mathlib@0.8.1.0/list.bend as List Lines 2688-2697 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=2688&end_line=2697 import Base # A right fold over a map folds with the mapped function: foldr g z (map f xs) = foldr (g . f) z xs, reversed to rewrite toward the simple side. law foldr_map_sym: for ~A: Type for ~B: Type for ~C: Type for ~f: A -> B for ~g: B -> C -> C for xs: List for -z: C {List.foldr(~&1, ~A, ~C, ~(x => y => g(f(x), y)), xs, z) == List.foldr(~&1, ~B, ~C, ~g, List.map(~A, ~B, ~f, xs), z) : C} Uses (5): https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Equal.sym https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=List https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=List.foldr https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=List.map https://jend.leeeet.dev/definition.txt?path=bend-mathlib@0.8.1.0/list.bend&name=foldr_map