Pagini recente » Cod sursa (job #1206107) | Istoria paginii runda/simulare-cartita-23/clasament | Cod sursa (job #1268080) | Cod sursa (job #824477) | Cod sursa (job #170650)
Cod sursa(job #170650)
const m:set of char=['a'..'z','A'..'Z'];
var ct,S,d:longint;
c1:char;
f:text;
begin
assign(f,'text.in'); reset(f);
d:=0;
ct:=0;
s:=0;
while (not eof(f)) do
begin
read(f,c1);
if c1 in m
then
begin
d:=d+1;
inc(S);
end;
if not(c1 in m) and (d<>0)
then
begin
inc(ct);
d:=0;
end;
end;
close(f);
assign(f,'text.out'); rewrite(f);
if ct=0 then writeln(f,'0')
else writeln(f,S div ct);
close(f);
end.