
theorem Th8:
  for L being non empty ZeroStr, s being AlgSequence of L holds len
  s > 0 implies s.(len(s)-1) <> 0.L
proof
  let L be non empty ZeroStr, s be AlgSequence of L;
  assume len s > 0;
  then len s >= 0 + 1 by NAT_1:13;
  then len s - 1 >= 1 - 1 by XREAL_1:9;
  then reconsider l = len(s) - 1 as Element of NAT by INT_1:3;
  assume
A1: s.(len(s)-1) = 0.L;
  now
    let i be Nat;
    assume
A2: i >= l;
    per cases by A2,XXREAL_0:1;
    suppose
      i = l;
      hence s.i = 0.L by A1;
    end;
    suppose
      i > l;
      then i >= l + 1 by NAT_1:13;
      hence s.i = 0.L by ALGSEQ_1:8;
    end;
  end;
  then
A3: l is_at_least_length_of s by ALGSEQ_1:def 2;
  len(s) < len(s) + 1 by NAT_1:13;
  then len(s) - 1 < len(s) + 1 - 1 by XREAL_1:9;
  hence contradiction by A3,ALGSEQ_1:def 3;
end;
