var
i,sum:integer;
f:text;
begin
assign(f,'kot.txt');
reset(f);
while not eof(f) do begin
readln(f,i);
if i mod 3 = 0 then sum:= sum + i;
end;
close(f);
assign(f,'kot2.txt');
rewrite(f);
writeln(f,sum);
close(f);
end.
__________________