-
-
Save shounaklohokare/e5b6a82a5dca97212cbcbfb2f64d4775 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
def kangaroo(x1, v1, x2, v2): | |
if x1 < x2 and v1 < v2: | |
return 'NO' | |
else: | |
if v1!=v2 and (x2-x1)%(v2-v1)==0: | |
return 'YES' | |
else: | |
return 'NO' |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment