@zimtsui/deque
TypeScript icon, indicating that this package has built-in type declarations

0.0.7 • Public • Published

deque

Npm package version

A double-ended queue with support for negative subscripts.

Comparison

Why not petkaantonov/deque?

Because it returns undefined rather than throws when range errors occur, and it takes time of O(n) to get an iterator.

Time complexity

  • push/pop/shift/unshift: O(1) on average
  • random access: O(1)
  • get iterator: O(1)

Readme

Keywords

none

Package Sidebar

Install

npm i @zimtsui/deque

Weekly Downloads

0

Version

0.0.7

License

none

Unpacked Size

33.1 kB

Total Files

18

Last publish

Collaborators

  • zimtsui