input Instance x;
output Locally optimal solution y;
begin
 y:=initial feasible solution;
 while there there exists a neighbour solution z of y better than y do
    y:=z;
 return y 
end.