Answer:
The gradient of a line is given by
.
Any 2 points of a vertical line would have the same x-coordinate. Thus when you simplify the denominator, you would end up with a zero. If you enter that into your calculator, no matter what you numerator is, you would get a Math error. This is because you cannot possibly divide a number by zero. Thus, the gradient is undefined.