Pagini recente » Cod sursa (job #1203404) | Cod sursa (job #351881) | Cod sursa (job #456854) | Cod sursa (job #1932209) | Cod sursa (job #931209)
Cod sursa(job #931209)
program fain;
var
c:char;
cuvinte,litere:integer;
fin,fout:text;
begin
assign(fin,'text.in');
reset(fin);
while not eof(fin) do
begin
read(fin,c);
if ((c>='a') and (c<='z')) or ((c>='A') and (c<='Z')) then
cuvinte:=cuvinte+1;
while (('a'<=c) and (c<='z')) or (('A'<=c) and (c<='Z')) do
begin
read(fin,c);
litere:=litere+1;
end;
end;
close(fin);
assign(fout,'text.out');
rewrite(fout);
write(fout,litere div cuvinte);
close(fout);
end.