1 3 4 10The program computes the slope and outputs both the points, and the resulting slope:

(1,3) (4,10) Slope: 2.33333Recall that the slope is defined as rise / run, or (y2-y1) / (x2-x1). In the previous exercise you were allowed to assume that the

*run*would never be 0, thus avoiding division by 0. This assumption is no longer true. Since division by 0 is mathematically undefined, your task in this assignment is to check for a run == 0.0, and output “Slope: undefined” in this case. Example: given the inputs

1 3 1 -3Your program should now output

(1,3) (1,-3) Slope: undefinedIn other words, your program should work as before except when the run is 0, in which case the output should be “Slope: undefined”. Hint: use an if-then-else statement to check the run, and decide whether to output the error message, or compute the slope and output. Feel free to read ahead to Chapter 3 (in particular section 3.1) for an overview of if-then-else statements.