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.
My test case #4 is failing, rest is good. Not sure for case N=4 , K = 2.
For example 1224/2142 = 12/21 ( remove 2 and 4), but also
1224/2142 = 24/42 ( remove 1 and 2).
Do we include above twice or only once?
Cookie support is required to access HackerRank
Seems like cookies are disabled on this browser, please enable them to open this website
Project Euler #33: Digit canceling fractions
You are viewing a single comment's thread. Return to all comments →
My test case #4 is failing, rest is good. Not sure for case N=4 , K = 2. For example 1224/2142 = 12/21 ( remove 2 and 4), but also 1224/2142 = 24/42 ( remove 1 and 2). Do we include above twice or only once?