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.
I am struggling with this kata quite a bit. I have a very verbose and not so elegant solution that seems to be passing the vast majority of test cases.
Now I think the error that im running into "Must return true if ships are touching" has to do with the priority that i use when removing ships. I start by removing the 4 cells, then 3, and then 2... however I have noticed that there are cases in which there can be multiple possible battleships and cruisers.
so I guess my question is, is backtracking required to solve this kata?
Awesome Thank you! I wasn't sure if the interpreter needed to fail on its own or if I could throw my own exception but throwing my own exception worked! Thanks Benjaminz!
Having a little trouble with a particular test case. Test case "124X212", In this test case the middle character is not apart of the arithmetic required to return if the lucky string is true or false, and therefore does not throw a python error. Does anyone know how I should handle a case like this?
Thanks
This comment is hidden because it contains spoiler information about the solution
While I enjoy the idea of this Kata the instructions are extremely unclear. There is a lot of considerations that need to be made to determine if a player should hit or not. This Kata does not help us outline the considerations that tell the players to hit or not to hit. Unless they are always supposed to hit until they achieve 21 but that seems kinda silly. The win conditions are also not outlined well and that causes a lot of confusion.
In its current state I would avoid this kata which is a shame cause it does seem like it could be a fun one :/ please update this!
Sorry, language is python
This comment is hidden because it contains spoiler information about the solution
In case anyone was interested my problem was something really simple :/ when I copy pasted the rankCalc function from the increaseLevel function i forgot to switch the variable being setted to find enemy rank from enemy level. Therefore "You've been defeated" would never occur since self.rank was always equal to self.calcRank(enemy).
Little tip for debugging. Scroll all the way down and use the tests at the bottom. The ones at the top while funny, will not provide you with insight necessary to debug.
This comment is hidden because it contains spoiler information about the solution
This comment is hidden because it contains spoiler information about the solution
This comment is hidden because it contains spoiler information about the solution
This comment is hidden because it contains spoiler information about the solution
This comment is hidden because it contains spoiler information about the solution
Having a little trouble with this one. I am writing this in Java and most of my returns are correct. I just would like some clarification because im getting some returns of
true
that should befalse
. Are these sets supposed to be 1 to 1? For example, if I havea: {11,11}
would i needb: {121,121}
for the function to returntrue
?Oh geez lol, thank you for pointing that out! its been driving me crazy ALL DAY.
Loading more items...