Pagini recente » Monitorul de evaluare | Cod sursa (job #2225) | Cod sursa (job #931131) | Arhiva de probleme | Cod sursa (job #162584)
Cod sursa(job #162584)
const litere:set of char=['a'..'z','A'..'Z'];
var f:text; c:char; n,t:longint; inceput:boolean;
begin
assign(f,'text.in');reset(f);
n:=0; t:=0; inceput:=false;
repeat
read(f,c);
if (c in litere) and not(inceput)then begin
inc(n);
inc(t);
inceput:=true;
end
else if inceput and (c in litere) then inc(T)
else inceput:=false;
until eof(f);
close(f);
assign(f,'text.out');
writeln(f,t div n);
close(f);
end.