Metamath Proof Explorer


Theorem fz1eqb

Description: Two possibly-empty 1-based finite sets of sequential integers are equal iff their endpoints are equal. (Contributed by Paul Chapman, 22-Jun-2011) (Proof shortened by Mario Carneiro, 29-Mar-2014)

Ref Expression
Assertion fz1eqb M 0 N 0 1 M = 1 N M = N

Proof

Step Hyp Ref Expression
1 fveq2 1 M = 1 N 1 M = 1 N
2 hashfz1 M 0 1 M = M
3 hashfz1 N 0 1 N = N
4 2 3 eqeqan12d M 0 N 0 1 M = 1 N M = N
5 1 4 syl5ib M 0 N 0 1 M = 1 N M = N
6 oveq2 M = N 1 M = 1 N
7 5 6 impbid1 M 0 N 0 1 M = 1 N M = N