Pagini recente » Cod sursa (job #317513) | Istoria paginii runda/simulareoji_2008_11-12 | Cod sursa (job #1540997) | Cod sursa (job #1110463) | Cod sursa (job #448504)
Cod sursa(job #448504)
program text15;
var f,g:text;
i,s,nr:longint;
t:extended;
stop:boolean;
c:char;
begin
assign(f,'text.in');
assign(g,'text.out');
reset(f);
rewrite(g);
s:=0;
nr:=0;
stop:=false;
while not eoln(f) do
begin
read(f,c);
if (c >='a') and (c <= 'z' ) or (c >='A') and (c <= 'Z') then begin inc(s); stop := true; end
else if ( stop ) then
begin
stop:=false;
inc(nr);
end;
end;
if (stop) then inc(nr);
t:=s / nr;
writeln(g,t:0:0);
close(f);
close(g);
end.