Blazing IASian
Two lines are perpendicular if the product of their slopes is -1 or one has a slope of 0 (a horizontal line) and the other has an undefined slope (a vertical line).
Refer: http://en.wikipedia.org/wiki/Slope