program z;
var x,y:real;
begin
readln(x);
y:=x^2-6x-1;
writeln(y);
end.