Cod sursa(job #48276)
Utilizator | Alex Mircescu alex_mircescu | Data | 4 aprilie 2007 16:51:50 |
---|---|---|---|
Problema | Text | Scor | 40 |
Compilator | fpc | Status | done |
Runda | Arhiva de probleme | Marime | 0.51 kb |
var u,cuv:longint;
wq:string;
ch:char;
lit:set of char;
begin
assign(input,'text.in');
assign(output,'text.out');
reset(input);
rewrite(output);
lit:=['A'..'Z','a'..'z'];
while not eoln do
begin
read(ch);
if ch in lit then
begin
wq:=wq+ch;
inc(u);
end;
if not (ch in lit) and (wq<>'') then
begin
inc(cuv);
wq:='';
end;
end;
if wq<>'' then
begin
inc(cuv);
end;
write(u div cuv);
close(input);
close(output);
end.