iawia С текстовыми - вот так:
Код
var
cnt: array['A' .. 'Z'] of integer;
s: string;
i: integer;
ch_max, ch: char;
f: text;
begin
assign(f, 'A.txt');
reset(f);
while not eof(f) do
begin
readln(f, s);
for i := 1 to length(s) do
if upcase(s[i]) in ['A' .. 'Z'] then inc(cnt[upcase(s[i])]);
end;
close(f);
ch_max := 'A';
for ch := 'B' to 'Z' do
if cnt[ch] > cnt[ch_max] then ch_max := ch;
writeln('max count for ', ch_max)
end.