Cod sursa(job #728935)
Utilizator | Isaila Ioan Andrei Iandrei96 | Data | 29 martie 2012 09:38:24 |
---|---|---|---|
Problema | Text | Scor | 0 |
Compilator | fpc | Status | done |
Runda | Arhiva de probleme | Marime | 0.65 kb |
var f,g:text;
c:char;
k,b,v:longint;
begin
assign(f,'text.in');reset(f);
assign(g,'text.out');rewrite(g);
k:=0;b:=0;v:=0;
while not eof(f) do
begin
read(f,c);
if ((ord(c)>64) and (ord(c)<92)) or ((ord(c)>96) and (ord(c)<124))
then begin
inc(k);
inc(b);
end
else if b<>0 then begin inc(v);
b:=0
end;
end;
write(g,b div v);
close(f);close(g);
end.