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.
perfect
JavaScript fork (author inactive)
chai
assertionsclass
andconst
, including in the initial codeAnother great kata challenge! This is very helpful for learning about accessing subarray indexes. Thanks!
Lua translation!
In R the naive solution may timeout, depending on the random test rolled. And since mine failed on the first try, I introduced memoisation. Sumbitted, passed (not sure now if coz of luck or not) and found the naive solution to be the "best" one.
Meh. :(
If imported properly as you shown, no prob.
If imported with
from solution import *
, you can import other symbols: seems obvious but it is often done, even in production code.Always better to avoid trivial names in test suite - that might collide with other imports/libraries.
I still would like to understand. only
f
andm
are imported:symbols used in
f()
andm()
will still refer to their value insolution.py
, not to the ones intest.py
, even if those happen to have the same name, wont they ? what am i mising ?Can still collide with user-defined functions though - as they are imported into test suites.
Nevertheless referee solutions have now a non-trivial suffix, so this issue is no longer relevant.
can you clarify the problem ? it seems not to be relevant anymore, now that Codewars no longer concatenates the solution file to the tests suite file for most languages, including Python
ranks are shared across languages and cannot be changed
For C, this seems like a 7 (or maybe 8), 6 is too high of a rating.
Latest fork approved by 🥕
added
Oriented Answer Programming
Took way too long to figure out that coffeescript wanted you to return an error object instead of throw one.
Loading more items...