You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
In Queue the dequeue should be O(1) complexity #942
Activity
ayDavidGitHere commentedon Mar 24, 2022
Dequeue on queue works on a O(n) complexity.
To achieve dequeue on O(1) use linked-lists.
https://github.com/ayDavidGitHere/Javascript/tree/master/Data-Structures/Linked-List
fahimfaisaal commentedon Mar 24, 2022
Yeah, I see.
appgurueu commentedon Apr 1, 2022
The queue should be implemented using linked lists. The current implementation is clearly suboptimal for no good reason.
raklaptudirm commentedon Apr 2, 2022
@fahimfaisaal Are you working on this issue?
fahimfaisaal commentedon Apr 2, 2022
Yep.. I'll send pr soon.
raklaptudirm commentedon May 6, 2022
@fahimfaisaal You still haven't sent a pull request. Are you working on this, or should I put this issue up for grabs?
fahimfaisaal commentedon May 6, 2022
@raklaptudirm I apologize for my latency.
raklaptudirm commentedon May 6, 2022
#1005 fixes this.