Ответ:
program Summa7;
var
n, i, s: Integer;
begin
Write ('N = ');
Readln (n);
s := 0;
for i := 7 to n do begin
if i mod 2 = 0 then
s := s + i;
end;
WriteLn ('Сумма четных чисел = ', s);
ReadLn;
end.
Copyright © 2024 SCHOLAR.TIPS - All rights reserved.
Answers & Comments
Verified answer
Ответ:
program Summa7;
var
n, i, s: Integer;
begin
Write ('N = ');
Readln (n);
s := 0;
for i := 7 to n do begin
if i mod 2 = 0 then
s := s + i;
end;
WriteLn ('Сумма четных чисел = ', s);
ReadLn;
end.