Loading collection data...
Collections are a way for you to organize kata so that you can create your own training routines. Every collection you create is public and automatically sharable with other warriors. After you have added a few kata to a collection you and others can train on the kata contained within the collection.
Get started now by creating a new collection.
This comment is hidden because it contains spoiler information about the solution
Where are the
x
ofldcxkfyrlcbdxsekl
inferzdffpubobgmilcnk
?B1ts, what you said doesn't matter, you can have more letters in s1.
s1: ferzdffpubobgmilcnk
s2: ldcxkfyrlcbdxsekl
I don't see
z
(4th char) included in the 2nd string.Edit: oops, I didn't read the task correctly, it's the other way around. So,
x
is in s2, but not in s1, so it can't be true.I clearly don't understand the Kata, because in my Attempts, I get false positives. An example: ferzdffpubobgmilcnk and ldcxkfyrlcbdxsekl. It appears to me, that this case should return True for ek, but according to the Attempts it should return False. What am I not understanding correctly?
In Python, are my two very different algorithms too slow or could it be related to the generation of long random test cases ? Is there a way to time each ?
It's not originally a Python kata ( it's maybe easier in Haskell ). Also, rank inflation.
That said, I can't fix it for you. Only an admin can, not even the person who approved it.
vv
I either time out but my logic is correct (checked out of CW) or I follow the hint to use s = (s % (M+1) + math.floor(s/(M+1))) % M and get an error:
OverflowError: integer division result too large for a float
Should we go bitwise arithmetic to solve this ? If so, not sure it is a 6kyu.
Doing it, very fun kata. I am coming to realise that a Test Driven Development approach to this one really helps, and I find it funny because I did not get what made TDD so useful until now!
i dont remember when i solved something myself.. so i dont think so
I spent 10 hours+ figuring out a mathematical solution based on triangular numbers and the hint that a solution existed without iteration. Keep trying. I'm probably dumber ;-)
sadly description of kata dosent help at all to solve this. and after seeing solutions it lead me to conclustion im too dumb for learning programing
What's the value of n there?
Python Test results are strange: [1,2,3,4,5,6,7 ] Expected result = 0 ?
Very hard kata.
Loading more items...