You can put this solution on YOUR website! If you plot x=-5, you get a vertical line where every point on that line has an x coordinate of -5.
Slope = delta y / delta x.
delta x would always be
But you know that a fraction with a zero denominator is undefined. So the slope is undefined for any vertical line.