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.
Best performance
For example when one char takes 2 bytes or more.
For example, Russian letter "Ш" takes 2 bytes.
It same for chinese hieroglyphs
I agree with you. This is more like a clever solution than best practice.
Hey I'm newer to Go and would like to learn more about this. When would the byte count vs char count be different using
len()
?Most of the people who write the solution in a 8kyu kata are new programmers, many of them don't even know what O notation is, I guess it's the highest ranked because it's easy to understand and easy to think about it. Kata tests do not measure performance, so it is not a flag. I agree with the down buttons. but i think that the kata tests will have any performance input like a lot of inputs or timing. I submit the sort version to, because is the faster way to write the solution, are only to instructions.
Agree. I wish there were down votes too. It may be missleading especially for novice programmers.
Why is this a best practice? Sorting complexity for sorting is about and is O(n * log(n)) and just iterating through the array will take O(n) that faster and simplier, e.g. for 1 billion array list the number of iteration for sorting will be about 30 billions.
Very clever, but slow lol