• + 3 comments

    Incorrect. (v1-v2) is NOT guaranteed positive. You still need to check if (x2 - x1)/(v1 - v2) or just v1 > v2 is positive to print out "YES"