You are viewing a single comment's thread. Return to all comments →
i think...
// given that x2 > x1, if v1 > v2 its a NO because kangaroo2 is already behind and cannot catchup by going slower than kangaroo1
// x2-x1 % v1-v2 this basically checks if the diff in the inital lead (x2-x1) can be made up by going faster
Seems like cookies are disabled on this browser, please enable them to open this website
Number Line Jumps
You are viewing a single comment's thread. Return to all comments →
i think...
// given that x2 > x1, if v1 > v2 its a NO because kangaroo2 is already behind and cannot catchup by going slower than kangaroo1
// x2-x1 % v1-v2 this basically checks if the diff in the inital lead (x2-x1) can be made up by going faster