hi sanchit
first of all mention the plane whether it is xy yz or zx plane ...
When the slope of the line is 0, you know that the line is horizontal
and you know it's a vertical line when the slope of a line is undefined.
in zx plane , z axis is reference line thus slope = 0
in yz plane its slope is same as the y axis in xy plane that is again undefined
and xy plane we donot talk about slope of the line which does not lie in xp plane !!!!