In coordinate geometry, whenever we solve a problem we see that if the resulting solution is a line, then all the lines which are parallel to y - axis are left out since their slope will be $\infty$ and thus can't be calculated. This is a big problem when solving questions since very often we tend to miss out on specific solutions or sometimes get no solution at all when the only solution is a line parallel to y - axis.
My way: I usually check out specifically for this case(taking the line to be $x = \lambda$) when I feel that there can be a potential solution.
Is there any better method of dealing with this problem ?
Any line can be represented as $$ax+by+c=0$$ where $a,b,c\in\mathbb R.$
Set $b=0$ in the equation.
Edit : In your 'new' question, it is clear that $x=1$ is one of the tangents. So, we may suppose that $y=mx+n$.