Use the intermediate value theorem.
Prove: If f is a continuous function whose domain includes a closed interval [a,b], and L is a horizontal line, and (a,f(a)) is below L, and (b,f(b)) is above L, then there is a number x between a and b such that (x,f(x)) is on L.
Thanks in advance for help.
in the given interval the function is continuous
now it means that there is no gap in the curve drawn(that is in your function)
now if one point is below the line and other is above the line it means that the function must cut the given horizontal line hence there is a point x,f(x) that must lie on line
(suppose you are suppose to draw a line using paint on floor while you were painting there was another line on the floor
1) one way is to keep on painting the floor and do not paint over the other line but doing this will make your line discontinuous hence to have a continuous line you will have to paint over the other line
same thing is happening in question that is to be continuous the function will have to intersect the line as one point it below and other is above so there will definetly be a point that lie on both of them i.e x,f(x) such that a<x<b. [here function can not take a jump as we are dealing with 2D graph]