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.
Massive W to all Java devs on StackOverflow
I hate how this is possible in python, yet so efficient
optimize the next one 😉
I'm just having fun 😏
This is kinda going back and forth lol, there is hardly much a difference
Thanks, I try to make my code as Pythonic as possible.
This is the most optimal, very elegant and precise!
I thought mine was the most optimal. Lol
This is impressive, didn't think a dunder could have been used
This is correct according to PEP 8 styling for python code but in terms of 1 liners, hardly most of them follow this structure. I guess it's all based on preference.
According to PEP 8 – Style Guide for Python Code
Additionally,
I don't think it matters if you use an import outside or inside since the code is still one line right?
as optimized as it can be for this kata. very short and concise!
You may be correct on that. I am not well versed on the time difference but even I can tell the first is faster by a margin. The first one however could be optimized.
I believe solution #1 is faster.
Loading more items...