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.
;-)
No more zeros in the denominator!
No, the expected result often adds up to 359 or 361.
The description should specify how to round half integers (up, down, ...).
pass random list in your solution before giving it to the user, just replace
with
The total of the resulting list doesn't really adds up to 360, just close to it.
The tests sometimes throw an exception:
I cheated and bypassed the kata security to use the random module. :)
huh?
pretty much the same thing as mine... not bad!
2*n == n*2
Yours seems slightly faster indeed, but around 10-20% depending on the size of the list.
And partly because of the extra layer of itemgetter.
For example with the same random tests as the kata and the same list of 1_000_000 tests for each one, I get the following results:
Mercy: 3.399389314651489 seconds
Oleg: 3.032890796661377 seconds
rowcased: 3.238804864883423 seconds
And while obviously not unreadable, your code takes just a little longer to get for a newcomer.
O(2n). Not the best one
This comment is hidden because it contains spoiler information about the solution
that is too much for my brain!!
;)
Fixed
omg this is so slay queen x
Loading more items...