你好,我有一个简单的程序,它在给定的文本中计算字符,直到行是空行,只有换行
var
znaki: array['a'..'z'] of integer = (0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0);
napis: String;
maly: String;
dlugosc: Integer;
znak: char;
begin
napis := 'a';
while napis[1] <> '#13#10'do
begin
readln(napis);
maly:=LowerCase(napis);
for dlugosc:=(length(maly)) downto 1 do
begin
znaki[maly[dlugosc]]:=znaki[maly[dlugosc]]+1;
end;
for znak:='a' to 'z' do
writeln(znak, ' ', znaki[znak]);
end;
end.
它在条件下失败,我不知道为什么。请给我线索