For the vertical asymptote, you need to make sure the function goes towards infinity at that point.
This means to check the limit at that point, and you do this by dividing out the factor like your teacher showed.

Here is an example.
Does the graph y = x have any vertical asymptotes? No right?
What about y = x^2 / x?
x = 0 makes it undefined, but it is the same as y = x at other values (it just has a "hole" at 0 but no "spike"). So you have to make sure you divide out as many factors as possible before concluding a point has a vertical asymptote. Does this make sense?