MPE Home Metamath Proof Explorer < Previous   Next >
Nearby theorems
Mirrors  >  Home  >  MPE Home  >  Th. List  >  lsw Structured version   Unicode version

Theorem lsw 12271
Description: Extract the last symbol of a word. May be not meaningful for other sets which are not words. (Contributed by Alexander van der Vekens, 18-Mar-2018.)
Assertion
Ref Expression
lsw  |-  ( W  e.  X  ->  ( lastS  `  W )  =  ( W `  ( (
# `  W )  -  1 ) ) )

Proof of Theorem lsw
Dummy variable  w is distinct from all other variables.
StepHypRef Expression
1 elex 2986 . 2  |-  ( W  e.  X  ->  W  e.  _V )
2 fvex 5706 . 2  |-  ( W `
 ( ( # `  W )  -  1 ) )  e.  _V
3 id 22 . . . 4  |-  ( w  =  W  ->  w  =  W )
4 fveq2 5696 . . . . 5  |-  ( w  =  W  ->  ( # `
 w )  =  ( # `  W
) )
54oveq1d 6111 . . . 4  |-  ( w  =  W  ->  (
( # `  w )  -  1 )  =  ( ( # `  W
)  -  1 ) )
63, 5fveq12d 5702 . . 3  |-  ( w  =  W  ->  (
w `  ( ( # `
 w )  - 
1 ) )  =  ( W `  (
( # `  W )  -  1 ) ) )
7 df-lsw 12235 . . 3  |- lastS  =  ( w  e.  _V  |->  ( w `  ( (
# `  w )  -  1 ) ) )
86, 7fvmptg 5777 . 2  |-  ( ( W  e.  _V  /\  ( W `  ( (
# `  W )  -  1 ) )  e.  _V )  -> 
( lastS  `  W )  =  ( W `  (
( # `  W )  -  1 ) ) )
91, 2, 8sylancl 662 1  |-  ( W  e.  X  ->  ( lastS  `  W )  =  ( W `  ( (
# `  W )  -  1 ) ) )
Colors of variables: wff setvar class
Syntax hints:    -> wi 4    = wceq 1369    e. wcel 1756   _Vcvv 2977   ` cfv 5423  (class class class)co 6096   1c1 9288    - cmin 9600   #chash 12108   lastS clsw 12227
This theorem was proved from axioms:  ax-mp 5  ax-1 6  ax-2 7  ax-3 8  ax-gen 1591  ax-4 1602  ax-5 1670  ax-6 1708  ax-7 1728  ax-9 1760  ax-10 1775  ax-11 1780  ax-12 1792  ax-13 1943  ax-ext 2423  ax-sep 4418  ax-nul 4426  ax-pr 4536
This theorem depends on definitions:  df-bi 185  df-or 370  df-an 371  df-3an 967  df-tru 1372  df-ex 1587  df-nf 1590  df-sb 1701  df-eu 2257  df-mo 2258  df-clab 2430  df-cleq 2436  df-clel 2439  df-nfc 2573  df-ne 2613  df-ral 2725  df-rex 2726  df-rab 2729  df-v 2979  df-sbc 3192  df-dif 3336  df-un 3338  df-in 3340  df-ss 3347  df-nul 3643  df-if 3797  df-sn 3883  df-pr 3885  df-op 3889  df-uni 4097  df-br 4298  df-opab 4356  df-mpt 4357  df-id 4641  df-xp 4851  df-rel 4852  df-cnv 4853  df-co 4854  df-dm 4855  df-iota 5386  df-fun 5425  df-fv 5431  df-ov 6099  df-lsw 12235
This theorem is referenced by:  lsw0  12272  lsw1  12274  lswcl  12275  ccatval1lsw  12288  lswccatn0lsw  12292  lswccat0lsw  12293  swrd0fvlsw  12344  wrdeqswrdlsw  12348  swrdlsw  12351  swrdccatwrd  12367  repswlsw  12425  lswcshw  12454  lswco  12471  swrd2lsw  12557  iwrdsplit  26775  lswn0  30263  wwlknext  30361  wwlknredwwlkn  30363  clwwlkgt0  30439  clwwlkn2  30443  clwlkisclwwlklem2a1  30446  clwlkisclwwlklem2a3  30448  clwlkisclwwlklem2a4  30451  clwlkisclwwlklem1  30454  clwwlkel  30460  clwwlkf  30461  clwwisshclwwlem  30475  wwlkextproplem2  30566  numclwwlkovf2ex  30684  numclwlk1lem2f1  30692  numclwlk1lem2fo  30693
  Copyright terms: Public domain W3C validator