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.
python new test framework
This comment is hidden because it contains spoiler information about the solution
python new test framework is required. updated in this fork
This comment is hidden because it contains spoiler information about the solution
This comment is hidden because it contains spoiler information about the solution
python new test framework is required. updated in this fork
final sample test does not comply with description
Description should be language-agnostic
Example and fixed tests on
j
included inplaintext
andsquare
should be testedMissing test framework and solution imports in Python tests
Lua translation!
The behavior of j and i is somewhat unclear from the description and example test cases. While you say j should be treated as i, neither the examples in the description nor in the test cases contain a "j" in the square paramater. They do, however, contain i's. Therefore, one might assume that the instruction meant to perform a j to i substitution on the plaintext. This has clearly confused others than just me.
I suggest altering the description to say:
If either an i or j appears in the encryption square text, the corresponding two-letter code should be used to encrypt both i and j.
Furthermore, you should remove all mention of a substitution from the decryption section of the description. It says(PLEASE NOTE, j SHOULD BE TREATED AS i)
, but this is incorrect. If a j appears in the square text for adfgx_decrypt, then if the corresponding two-letter code appears in the ciphertext, your tests expect a j, not an i.JS: Node v12 should be used along with the appropriate assertion tools (Mocha + Chai)
In python the natural way to return multiple values is using a tuple, not a list.
Rounding prevents correct float comparision. Two similar values (within tolerance) may be rouded to different values.
Floats should be compared with
test.assert_approx_equals
.Encryption/decryption functions should be called once per test-sequence.
Loading more items...