5 kyu
Castle of Cubes
Loading description...
Algorithms
View
This comment has been reported as {{ abuseKindText }}.
Show
This comment has been hidden. You can view it now .
This comment can not be viewed.
- |
- Reply
- Edit
- View Solution
- Expand 1 Reply Expand {{ comments?.length }} replies
- Collapse
- Spoiler
- Remove
- Remove comment & replies
- Report
{{ fetchSolutionsError }}
-
-
Your rendered github-flavored markdown will appear here.
-
Label this discussion...
-
No Label
Keep the comment unlabeled if none of the below applies.
-
Issue
Use the issue label when reporting problems with the kata.
Be sure to explain the problem clearly and include the steps to reproduce. -
Suggestion
Use the suggestion label if you have feedback on how this kata can be improved.
-
Question
Use the question label if you have questions and/or need help solving the kata.
Don't forget to mention the language you're using, and mark as having spoiler if you include your solution.
-
No Label
- Cancel
Commenting is not allowed on this discussion
You cannot view this solution
There is no solution to show
Please sign in or sign up to leave a comment.
This comment has been hidden.
Can the attempt test cases remove the duplicates? See below.
Failed for n = 7: _ Failed for n = 25: _ ... Failed for n = 7: _ ... Failed for n = 25: _
Something is not correct when finally attempting this kata in python 3.8. My solution does not have any recursion. There is a single, exterior def, also not recursive, with a single print statement. That exterior def is called at-most twice, yet I see dozens of lines printed out per test. The sample tests work exactly as expected: I see at most two lines, and my solution passes the sample tests.
If there are 100,000 tests, instead of having 999,990 pass and 10 fail, this just returns 10 fail.
Change Kata level to 4 or 3
I would like to, but i don't find the option, don't know how to do it. Can someone help me with that ?
You can't.
Thank you. So is there any way this level may evolve ?
Exelent Kata, which almost made me cry and tear my hair out if I had some... But this should not be 5 kyu, I'd say it should be 4 or 3 as I've done couple 5-6 level kyus and this one is just way more complex..
This comment has been hidden.
Hi, does a celing/floor conection count in the "Neighboring rooms share one same panel between them." bit? If it does, I can't see how you get more than two rooms connected. And if I had one room on its own, should the area not be 5 since the ground acts as a barrier?
Hi, the ground doesn't count as a barrier, each room needs a panel for its ground too. And ceiling/floor can be shared as well between piled neighbors.
does it only tell you if you fail a test? (not if you pass one)?
I've misread the description >_< I read "Neighboring rooms share one same panel between them" to mean a maximum of one panel (rather than they may). That what probably me being stupid.
Nothing stupid in your questions for me, my decription is short and would certainly deserve a picture. That was my first kata, i like the problem, but the kata creation is not very good. I wasn't aware of the codewars_test toolbox. So yes, it only tells when a test fails.
Input range and number of tests is not specified, and there are apparently lots of them in the actual tests. They should be documented.
Thank you Voile, Informations added to the description.
Hi,
n=7,25 and 22
thanks ! tests added
In the sample tests the arguments of
assert_equals
are in the wrong order.Oups ! Thanks, fixed.
snake_case
is strongly preferred for function names in Python. I think nouns used as determiners should be singular (panel_count
)?.. https://english.stackexchange.com/questions/349475/singular-or-plural-noun-preceding-count https://www.usingenglish.com/forum/threads/242655-Plural-or-singular-when-using-with-the-word-countThank you ! It's corrected now.
Displaying test results requires more than 900 MiB of memory. I'm not sure what kind of tests there are, but the tests should be grouped in some way.
This comment has been hidden.
This comment has been hidden.
Just compare normally and only call
assert_equals
if there's a failure.Thank you for your help, i think it's ok now.
Looks good, but there are messages like "1 should equal 0".
test.expect(False/True)
should be used in cases like this.And this is fixed too. Nice solution btw !!
Do you agree on the estimated level for this kata ?
I vote for 4 kyu, maybe even 3.
Needs sample tests
Ok now
This comment has been hidden.
Hi, thank you for your help, I'm new to kata creation, and a little lost with the editor. Is that ok, now ?
same here
fixed