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.
ehhh its not finished, but originally it was because slower solutions at n^3 could pass, and because math.random was being used, also plan on updating test suite, but performance is not a requirement for now
What's the goal of this fork? Is it an answer to some specific issue?
the k=0 rule would make sense if the problem was turned into a problem where you have to select the amount of dice with n being the limit
@_@, but currently for every other output it seems to only care about the sum if u rolled all the dice
Is it ok if we speed, up the reference solution and tests?
I got it!!
Thanks a lot man <3
The
String.split(String s)
splits the string into an array of strings in places where there is s in the original string. So you have something like"hello world!"
, and if you do"hello world!".split(" ")
it will split the string into an array like this:{"hello", "world!"}
Then with the
[0]
he is accessing the first element of the array. 0 is the first element in Java and you access array elements by an index with square brackets, remember!Good code bro, i'm new with Java, can you explain what that means please?
what else!!!?
big woops, either way fixed
Should have both the testcase & solution imports in the sample test. I still see only the solution import in there
i think my new changes should do it
Sample test cases: Missing testcase & solution imports
Test cases: Missing solution import
After importing the user solution explicitly, you might notice some error popping out. This is because...
Actual test cases should not be using the variable
p
that was automatically imported from the user solutionUsers can still pass this kata without using
^
in their regex.I suggest using
re.search
overre.match
to match the behaviour of other translations. Python documentation: search() vs. match()re.match() checks for a match only at the beginning of the string
re.search() checks for a match anywhere in the string
2,2 can only produce even numbers, so the largest value any whole number amount of those 2 coins cannot make is an infinite odd number, feel free to ask more questions ^^
i don't understand why coins(2, 2) should return -1, if the biggest combination that those numbers can't get is 1, becouse they can't reach the number one with an integer combination.
Stripping? Sir, this is a codewars Kata.
Loading more items...