Closed Mudtjn closed 3 months ago
Thanks, having a look.
return true;
case is used.I am unable to understand what it means about when will or else part of if(keypair) will hit. But have fixed increment conditions for the index.
The keys array is a queue that will be filled by the first async loop, while the second async loop consumes the keys. Wouldn't there be a problem if the index = 5
and there are 3 elements in the array? They won't be checked. Using pop()
prevents this.
I was suggesting not to pop elements from keys array. I have used index to bypass the need to pop the elements from array. I won't be popping elements while using index.
There needed to be a condition, where if there is no start and end condition then the keypair is already a match. Also popping constantly from the keys array is a costly operation and using index to take keys.