(* We find the maximum of f(x,y) = x y on the circle x^2+y^2 = 1 *)
f=x y
g=x^2+y^2
ContourPlot[f,{x,-1,1},{y,-1,1}]
ContourPlot[{g==1},{x,-1,1},{y,-1,1}]

Gf=Grad[f,{x,y}]
Gg=Grad[g,{x,y}]

sol=Solve[{Gf==alpha Gg,g==1}]

s1={x,y,f}/.sol[[1]] 
s1 //N

s2={x,y,f}/.sol[[2]] 
s2 //N

s3={x,y,f}/.sol[[3]] 
s3 //N

s4={x,y,f}/.sol[[4]] 
s4 //N

(* Global maximum of 0.5 at (1/sqrt(2),1/sqrt(2)) and (1/sqrt(2),1/sqrt(2)) *)
(* Global minimum of -0.5 at (1/sqrt(2),-1/sqrt(2)) and (-1/sqrt(2),1/sqrt(2)) *)