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.
Thanks! Yes, I found O(n) solution and passed tests successfully
The final tests contain 50 tests with ~1k elements and 10 tests with ~20m elements. Make sure you can pass all within the timeframe of your language.
Clever solution. We can use result.setCharAt(index, ')'); to make less discussions about StringBuilder::replace
Hi! There is a solution with O(n) time complexity. Good luck!
Hi! When I try to attempt Java17 solution I get exception "Timed Out (16000 ms)" in randomTests. My solution has O(n* n) and I optomized it with multithreading. That give me speed about 11 sec on local mashine with array of 10000000 size. Is there any better solution? Or is it problem with codewars server?