Var
n,k: Integer;
BEGIN
Writeln('Введите N: '); Readln(n);
Writeln('Введите K: '); Readln(k);
If n mod 4=0 Then Writeln(4*k)
Else If n mod 4=2 Then Writeln(4*k+2)
Else If n mod 4=3 Then Writeln(4*k+3);
END.
var a,b,c:integer;
begin
readln(a);
c:= (a mod 4);
case c of
0: begin b:=a div 4;
write(a,'=4*',b);end;
1: begin b:=a div 4;
write(a,'=4*',b,'+1');end;
end;
end.
n,k: Integer;
BEGIN
Writeln('Введите N: '); Readln(n);
Writeln('Введите K: '); Readln(k);
If n mod 4=0 Then Writeln(4*k)
Else If n mod 4=2 Then Writeln(4*k+2)
Else If n mod 4=3 Then Writeln(4*k+3);
END.
begin
readln(a);
c:= (a mod 4);
case c of
0: begin b:=a div 4;
write(a,'=4*',b);end;
1: begin b:=a div 4;
write(a,'=4*',b,'+1');end;
end;
end.