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.
Java Translation
I just finished this, however, my first impression was that N was included as the integer component if the integer was 0 regardless of fraction part. So input of 0,0 --> N and input of 0,3 for instance -> N:.
Having completed the kata and reread it seems like this isn't the case and 0,3 would just be :. and N is only when 0,0. However, due to the lack of test cases I am still unsure.
It seems like this is worth clarifying in the description and/or in a test case. Thanks!
Suggestion: At the end of the description, after "with player 2 eventually winning", add something like "so the program should return 1, the player's index."
I think this will prevent the confusion that many people have encountered, as indicated futher down in the discourse below. The description does state at the top that the index should be returned, but it's easy to forget this by the time you get to the bottom.
Description should be language agnostic (Function call in example should be replaced)
Two information which may help other codewarriors, which are missing (or I could not deduce it from the kata details) from the details of this kata (for those who, like me, did not know how the Enigma machine works):
1- The "Dot" letter has an influence on the notch. As a matter of fact, the dot letter leads to an offset between the notch and the visible position in the window.
Example:
If notch is "Q" and dot letter is "A", then the notch causes rotation when "Q" is displayed in the window. No change, Dot is in initial position.
If notch is "Q" and dot letter is "Z", then the notch causes rotation when "P" is displayed in the window, because Z has an offset of 25 towards A (0 position) => Q + offset of 25 gives "P".
If notch is "Q" and dot letter is "M", then the notch causes rotation when "C" is displayed in the window, because M has an offset of 12 towards A (0 position) => Q + offset of 12 gives "C".
2- When kata says "While in the actual usage of the original Enigma Machine, punctuation was encoded as words transmitted in the stream, in your code any input character that is not in the range A-Z should be returned unchanged and should not affect the internal state of the machine.", the "A-Z" is to be case-sensitive understood.
That is "A-Z" will be ciphered and crypted, punctuation will leaves the machine status as is (no rotation, no ciphering) ... but range "a-z" will ALSO remains untouched.
missing useful imports.
Description should be language-agnostic
Java translation
python new test frameworks
This comment is hidden because it contains spoiler information about the solution
As stated at Wikipedia:
So I think it should be mentioned in description that which method(1, 2, 3, or 4) should be used for calculating lower and upper quartile of a sequence with odd number of data.
python new test framework is required. updated in this fork
This comment is hidden because it contains spoiler information about the solution
In Java, it is rather hard to read values from
Limit
if the names of the exposed variables are never mentioned, and the definition ofLimit
is not available.Also missing an edge case where
required = 0
and hence should return0
.Loading more items...