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 mistakenly approved a more recent fork first, where they edited the description. Now they wont let me approve yours. Can you please edit your description to match the new one so I can approve it?
I think you need to change this. This was tripping me up too. I honestly don't have much insight into how hypothetical truck drivers feel about their cargo, fuel tanks, or whatever this cylinder is. The wording needs to speficy that the problem is asking for the volume of liquid in the tank. I also interpreted "the remaining volume" to mean "the empty space."
It's what came to mind first :P
substr is different from substring. the first parameter computes the correct starting location of the substring by using Math.ceil, and the second parameter tells substr (not the same as substring) to get the next 1 or 2 characters depending on the parity of the length of the string.
Thanks! I'll get to the random test cases asap.
Thanks for observation, should be fixed now, please double check.
Thanks for observation, should be fixed now, please double check.
Yeah, I tried to throw curve balls by being inconsistent with casing and ended up getting mixed up myself. Thanks for observation.
Thanks for your help
Ahh there we go. I didn't notice that the problem solution and test cases were not in accordance with the problem statement. Should be fixed now; thanks a lot for your help.
Thanks for your input. I'm new to codewars and I've been getting some conflicting advice with regard to assertEquals vs expect. Fixed it to reflect your suggestions other than the grouping by decribe and it, since this is an 8 kyu kata.
Could you please mark as resolved?
Thanks a lot! Sorry I couldn't fix my own errors, have had some bad personal situations come up.
Needs more examples and test cases. Also, instructions need to make it evident whether this array is only of primitive types and strings or whether it can hold other arrays, objects, etc.
Hey, could anyone tell me if there is any kind of performance measures here? Will it be acceptable if I parse/compute the solution in multiple passes? I can't figure out how to crack the dual unary/binary nature of the minus sign with a regular left-to-right reading solution with the operator and operand stack.
My JS code runs in under 0.15ms for the all test cases on my machine, yet it was timing out on codewars. I gave up on the problem thinking that I just wasn't seeing the algorithm correctly and that there must have been an O(n) solution I didn't know about, but this wasn't the case and I'm pretty bummed that I missed out on the honor =/
I should have tested my local running time before giving up I guess. Great Kata though, I would rate the difficulty at 3 kyu.
Loading more items...