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.
don't code like this !
lines don't cost money
spending ages trying to read code does cost money
bugs cost a fotune!
https://docs.codewars.com/authoring/guidelines/translation/
"Do not translate kata into languages where the difficulty would significantly differ"
The SQL version is significantly harder
Should it really exists as a translation ?
Functions in SQL are an advanced issue.
I can see that in teh JavaScript version - but not in the Go version I was workng on
Some of these kata are more about figuring out the maths than writing code
Once you have the formula - the code is fairly simple
I think the description could also be clarified.
It's not exactly "how many cubes of any size can fit inside a
x*y*z
box"but rather "how many ways can you fit a cube of any size inside a
x*y*z
box"So for example a
2*2*2
cube could fit in a2*2*3
box in two ways (with the zero point either at 0,0,0 or 0,0,1)Stiil - part of the challenge in coding is interpreting imprecise specifications.
I think the description should tell you it requires you to use a new array instead of modifying the input array
Otherwise we have to guess at hidden requirments (not that I haven't had to do that in real life but it seems mean for a beginner level kata)
Worth noting that performing this action on passwords is against best practise guidelines
It could still be a useful regex practise - just don't do this as part of real password validation
https://github.com/OWASP/ASVS/blob/v4.0.3/4.0/en/0x11-V2-Authentication.md
V2.1 Password Security
2.1.9