program Nok;
var
a, b, i: Integer;
begin
Write ('Введите 2 числа: ');
ReadLn (a, b);
if a < b then
i := a
else
i := b;
repeat
Inc (i);
until (i mod a = 0) and (i mod b = 0);
WriteLn ('НОК = ', i);
ReadLn;
end.
program Nok;
var
a, b, i: Integer;
begin
Write ('Введите 2 числа: ');
ReadLn (a, b);
if a < b then
i := a
else
i := b;
repeat
Inc (i);
until (i mod a = 0) and (i mod b = 0);
WriteLn ('НОК = ', i);
ReadLn;
end.