Cod sursa(job #179332)

Utilizator AndreiDDiaconeasa Andrei AndreiD Data 15 aprilie 2008 20:07:06
Problema Text Scor 30
Compilator fpc Status done
Runda Arhiva de probleme Marime 0.31 kb
const m:set of char=['a'..'z','A'..'Z'];
var i:longint;
ct,S,d:longint;
c1:char;
f,g:text;
begin
assign(f,'text.in');reset(f);
assign(g,'text.out');rewrite(g);
ct:=0;
s:=0;
while not eof(f) do begin
read(f,c1);
if c1 in m then inc(S)
else inc(ct);
end;
write(g,s div ct);
close(f);
close(g);
end.