Question:
Let \[f(x) =
\begin{cases}
3x^2 + 2&\text{if } x\le 3, \\
ax - 1 &\text{if } x>3.
\end{cases}
\]Find $a$ if the graph of $y=f(x)$ is continuous (which means the graph can be drawn without lifting your pencil from the paper).

Answer:
If the graph of $f$ is continuous, then the graphs of the two cases must meet when $x=3$, which (loosely speaking) is the dividing point between the two cases.  Therefore, we must have $3(3^2) + 2 = 3a - 1$.  Solving this equation gives $a = \boxed{10}$.