<s>[INST] Maximize $k=x^2+y^2$ Subject to $x^2-4x+y^2+3=0$ Question 
Let $x$ and $y$ be real numbers satisfying the equation $x^2-4x+y^2+3=0$. Find the maximum and minimum values of $x^2+y^2$. 
My work
Let $k=x^2+y^2$
Therefore, $x^2-4x+y^2+3=0$ ---> $k-4x+3=0$ .
What do I do next? How do I find an expression in terms of $k$ that I can maximize?
 [/INST] Hint 
The equation you have is that of a circle,  $(x-2)^2+y^2= 1$, and you want the maximum of $x^2+y^2=4x-3$. Clearly from the latter we need the extreme possible $x$, which from the circle's equation will be when $x\in \{1,3\}$.
</s>