Pagini recente » Cod sursa (job #1144395) | Istoria paginii runda/cerculdeinfo-lectia6-arbori | Cod sursa (job #1072180) | Cod sursa (job #1245304) | Cod sursa (job #726829)
Cod sursa(job #726829)
var f:text;
cl,cc:longint;
mid:longint;
c:char;
const ALPHA = ['A'..'Z', 'a'..'z'];
begin
cl:=0;
cc:=0;
assign(f, 'text.in');
reset(f);
while EOF(f) = false do begin
read(f, c);
if c in ALPHA then
cl:=cl+1;
if c = ' ' then
cc:=cc+1;
end;
close(f);
assign(f, 'text.out');
rewrite(f);
cc:=cc+1;
mid:=Trunc(cl/cc);
write(f, mid);
close(f);
end.