Why am I getting zero for all values in this expression?
<p>Following is a fragment of a program for deducing whether or out 2 lines intersect.
<code>P and P2</code> are <code>CPoint</code> objects marking the start and end point of one of the 2 lines.</p>

<pre><code>double m1,m2;  //slopes
double b1,b2;     //y-intercepts
double y,x;     //intersection point

m1=(max(P.y,P2.y) - min(P.y,P2.y)) /( max(P.x,P2.x) - min(P.x,P2.x) );
</code></pre>

<p>For some reason I'm always getting <code>m1</code> to be <code>0</code>. Why's that?</p>
