Pagini recente » Cod sursa (job #269861) | Cod sursa (job #404183) | Cod sursa (job #1205595) | Cod sursa (job #723700) | Cod sursa (job #22388)
Cod sursa(job #22388)
const litere=['A'..'Z'];
var c1,c2:char;
i,l,c:byte;
begin
assign(input,'text.in');reset(input);
assign(output,'text.out');rewrite(output);
l:=1;c:=0;
while not eoln do begin
read(c1);
if upcase(c1) in litere then inc(l);
if (upcase(c1) in litere)and (not(upcase(c2) in litere)) then inc(c);
c2:=c1;
end;
if c=0 then writeln(c)
else writeln(l div c);
close(input);close(output);
end.