Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Prove list_drop_app #84

Merged
merged 2 commits into from
Aug 16, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 8 additions & 2 deletions Katydid/Std/Lists.lean
Original file line number Diff line number Diff line change
Expand Up @@ -816,8 +816,14 @@ theorem list_drop_app_length (xs ys: List α):

theorem list_drop_app (n: Nat) (xs ys: List α):
drop n (xs ++ ys) = (drop n xs) ++ (drop (n - length xs) ys) := by
-- TODO
sorry
induction xs generalizing n with
| nil => simp
| cons x xs ih =>
cases n with
| zero => simp
| succ n =>
simp
exact ih n

theorem list_take_length_prefix_is_prefix (xs ys: List α):
take (length xs) (xs ++ ys) = xs := by
Expand Down
Loading