Data update

This commit is contained in:
Ingy döt Net 2026-02-01 16:33:20 -08:00
parent 5150844a7d
commit 4bb20c9b71
7735 changed files with 38060 additions and 199180 deletions

View file

@ -1,22 +0,0 @@
with Ada.Text_IO; use Ada.Text_IO;
procedure Test_Collapsible is
procedure Collapse (S : in String) is
Res : String (1 .. S'Length);
Len : Natural := 0;
begin
Put_Line ("Input = <<<" & S & ">>>, length =" & S'Length'Image);
for I in S'Range loop
if Len = 0 or else S(I) /= Res(Len) then
Len := Len + 1;
Res(Len) := S(I);
end if;
end loop;
Put_Line ("Output = <<<" & Res (1 .. Len) & ">>>, length =" & Len'Image);
end Collapse;
begin
Collapse ("");
Collapse ("""If I were two-faced, would I be wearing this one?"" --- Abraham Lincoln ");
Collapse ("..1111111111111111111111111111111111111111111111111111111111111117777888");
Collapse ("I never give 'em hell, I just tell the truth, and they think it's hell. ");
Collapse (" --- Harry S Truman ");
end Test_Collapsible;

View file

@ -1,8 +1,6 @@
func$ collapse s$ .
for c$ in strchars s$
if c$ <> cc$
r$ &= c$
.
if c$ <> cc$ : r$ &= c$
cc$ = c$
.
return r$