The function f is defined above. For what value of k , if any, is f continuous at x=2?

Answer: 3
Given:
[tex]f(x)=\begin{cases}x^2-3x+9{\text{ }for\text{ }x\leq2} \\ kx+1\text{ }{\text{ }for\text{ }x>2}\end{cases}[/tex]First, we find the limit of the function approaching from both sides when x=2:
Left-hand limit:
[tex]\begin{gathered} \lim_{x\to2^-}x^2-3x+9 \\ =(2)^2-3(2)+9 \\ =4-6+9 \\ =7 \end{gathered}[/tex]Right-hand limit:
[tex]\begin{gathered} \lim_{x\to2^+}kx+1 \\ =k(2)+1 \\ =2k+1 \end{gathered}[/tex]Hence,
[tex]\begin{gathered} 2k+1=7 \\ 2k=7-1 \\ 2k=6 \\ k=\frac{6}{2} \\ k=3 \end{gathered}[/tex]Therefore, the answer would be k=3