We use cookies to ensure you have the best browsing experience on our website. Please read our cookie policy for more information about how we use cookies.
I found y didn't really need to be calculated if using a loop that performs the x1+v1 and x2+v2 calculation at the same time. That way you can do a simple check at the beginning of each calculation to see if their positions are equal
Cookie support is required to access HackerRank
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 found y didn't really need to be calculated if using a loop that performs the x1+v1 and x2+v2 calculation at the same time. That way you can do a simple check at the beginning of each calculation to see if their positions are equal