var a:array[1..100] of integer;
s,i: integer;
begin
for i:=1 to 10 do begin
write('a[',i,'] = ');
readln(a[i]);
end;
for i:=1 to 10 do begin
if a[i] mod 3 = 0 then begin
s:=s+a[i];
end; end;
writeln('summa chisel kratnx 3 = ', s);
readln;
end.
Ответ:
program z1;
var a, b: integer;
begin
if a mod 10 < b mod 10 then
begin
write(a mod 10);
end
else
begin
write(b mod 10);
end;
end.
var a,b,c: integer;
begin
a:=2;
b:=6;
c:=a+b;
writeln(c);
end.
Значение "c" будет равняться 8.