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.
fixed - updated the description
Email script differ between description and tests:
"(...)Unfortunately, you have selected a bad(...)"
(description)vs.
"(...)Unfortunately you have selected a bad(...)"
(test).It probably should, but I believe that was not the point of your original remark.
Perhaps this issue would benefit from being re-written with appropriate cases. It's a waste of time to work with inconsistent input, as the saying goes - "garbage in, garbage out." In reality, people work with actual data rather than just descriptions of it. When something goes wrong, it's necessary to provide the dataset that caused the issue. I find it amusing that many computer science challenges focus on "corner" cases. In my experience working on production problems, developers don't typically think about "corner" cases; they focus on addressing the specific problem at hand. While there may always be another "corner" case that arises, the sheer number of potential cases is unlimited, so the idea of covering them all is unrealistic.
Maybe the default test should include result validation? :-)
I'm not aware of any errors. Correct solution passes tests just fine.
Which test did fail for you with that 'expected result'?
The default test - the only with the above dataset - doesn't include result validation.
Is something wrong with the simple test?
The above obviously do not overlap, but the expected result is
Very challenging kata, very good thing to learn how to count overlaps. Had to draw a lot of diagrams just visualise what my query is attempting to do.
Sets the name (alias) of result column.
What does "as mod" do?
You're right on all counts! Thanks!
Your interpretation of exit_time description and start=exit is correct.
Wording of exit_time definition was specifically chosen to express interval
openess and covers points 2 and 3 and, by extension, point 1.
I don't believe further extension of specification is needed.
Your solution seems to incorrectly handle case described in p. 2.
I've noticed it sometimes fails two. The other:
Btw, hey, Codewars Team! The formatting doesn't seem to work in this comment the same way as in my previous.
I interpret it as ends not belonging to the intervals. It then shouldn't matter if the starts do, and if entry_time equals exit_time, the interval is empty and the event doesn't count.
I assume entry_time > exit_time is impossible and not tested for.
Am I right?
(I believe my solution is correct under the above assumptions, yet it fails one test:
.)
The description leaves some things unspecified.
Loading more items...