def drop
import bend-collections-laws-math@1.0.0.0/spec/lib/common.bend as Commonimport Base
163def drop(-A: Data, xs: List<&2, A>, n: Nat) -> List<&2, A>:
164 match xs n:
165 case Nil{} _:
166 Nil{}
167 case Con{h, t} 0n:
168 Con{h, t}
169 case Con{h, t} 1n+p:
170 drop(A, t, p)
Uses (2)
Used by (5)
- bend-collections-laws-math@1.0.0.0/proofs/lib/list:sc_drop_take
- bend-collections-laws-math@1.0.0.0/proofs/lib/list:sc_take_split
- bend-collections-laws-math@1.0.0.0/proofs/lib/two_list:len_drop
- bend-collections-laws-math@1.0.0.0/proofs/lib/two_list:split_eq
- bend-collections-laws-math@1.0.0.0/proofs/lib/two_list:take_drop