Pagini recente » Cod sursa (job #1237269) | 24_februarie_simulare_oji_2024_clasa_9 | Cod sursa (job #2007306) | Cod sursa (job #854744) | Cod sursa (job #608545)
Cod sursa(job #608545)
program textulet;
var f:text;c:char;cuv,lit:longint;k:byte;
begin
assign(f,'text.in');
reset(f);
cuv := 0; lit := 0; k := 0;
while not eof(f) do
begin
read(f,c);
if upcase(c) in ['A'..'Z'] then
begin
inc(lit);
if k = 0 then
begin
inc(cuv);
k := 1;
end;
end
else k := 0;
end;
close(f);
assign(f,'text.out');
rewrite(f);
write(f,lit div cuv);
close(f);
end.