Physlib.Mathematics.ForMathlib.List
List lemmas
1 declaration
theorem
for prefix-closed
Let be a type and be a decidable predicate on . Let be a list of elements of type . Suppose that for any indices such that , if the element at index satisfies , then the element at index must also satisfy (i.e., the property is "prefix-closed" on ). Then, for any index , removing the -th element from and then taking the longest prefix of elements satisfying is equivalent to taking the longest prefix of satisfying and then removing its -th element.
