diff --git a/HackerRank-Kangaroo/Kangaroo.py b/HackerRank-Kangaroo/Kangaroo.py index b5b82b8..d5c4533 100644 --- a/HackerRank-Kangaroo/Kangaroo.py +++ b/HackerRank-Kangaroo/Kangaroo.py @@ -8,12 +8,21 @@ # Complete the kangaroo function below. def kangaroo(x1, v1, x2, v2): - for n in range(10000): - if((x1+v1)==(x2+v2)): - return "YES" - x1+=v1 - x2+=v2 - return "NO" + while(True): + if(v1>v2 and x1v1 and x2 pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy