Pagini recente » Cod sursa (job #2433740) | Cod sursa (job #231389) | Cod sursa (job #179632) | Cod sursa (job #2776952) | Cod sursa (job #210818)
Cod sursa(job #210818)
program gaju;
var f,g:text;
x:char;
act,pre:boolean;
cuv,text:longint;
begin
assign(f,'text.in');reset(f);
assign(g,'text.out');rewrite(g);
act:=false;pre:=false;
while not eof(f) do begin
read(f,x);
if (x in['a'..'z'])or(x in ['A'..'Z'])then begin
act:=true;
inc(text);
end
else act:=false;
if (pre=false)and(act=true)then inc(cuv);
pre:=act;
end;
writeln(g,text div cuv);
close(g);
end.