New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

queue-typed

Package Overview
Dependencies
Maintainers
1
Versions
162
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

queue-typed - npm Package Compare versions

Comparing version 1.32.2 to 1.32.9

docs/.nojekyll

82

package.json
{
"name": "queue-typed",
"version": "1.32.2",
"version": "1.32.9",
"description": "Queue, ArrayQueue. Javascript & Typescript Data Structure.",

@@ -21,15 +21,73 @@ "main": "dist/index.js",

"queue",
"data-structure",
"fifo",
"FIFO",
"lifo",
"LIFO",
"javascript",
"java script",
"JavaScript",
"js",
"typescript",
"type script",
"TypeScript",
"ts",
"job",
"work",
"queue",
"queue js",
"job queue",
"job scheduling",
"algorithm",
"concurrency",
"queue-management",
"promise",
"FIFO",
"LIFO",
"buffer",
"task-queue",
"job-queue",
"nodejs",
"job-scheduling"
"task queue",
"sorted",
"sorting",
"sort",
"ordered",
"data",
"structure",
"structures",
"data structure",
"datastructure",
"data-structure",
"data structures",
"datastructures",
"data-structures",
"in data structures",
"in data structure",
"DataStructure",
"DataStructures",
"traversal",
"iterate",
"Node.js",
"CommonJS",
"ES6",
"UMD",
"esmodule",
"java.util",
"c++ std",
"Python collections",
"System.Collections.Generic",
"STD",
"std",
"util",
"collection",
"Collection",
"collections",
"Collections",
"q",
"linked list",
"array",
"enqueue",
"dequeue",
"push",
"shift",
"next",
"node",
"item",
"searching",
"performance",
"OOP",
"documentation",
"visualization"
],

@@ -60,4 +118,4 @@ "author": "Tyler Zeng zrwusa@gmail.com",

"dependencies": {
"data-structure-typed": "^1.32.2"
"data-structure-typed": "^1.32.9"
}
}

@@ -5,8 +5,15 @@ # What

In the usual gig, we make do with Array.push and Array.shift to play Queue in JavaScript, but here's the kicker – native
JavaScript Array isn't exactly Queue VIP. That shift move? It's a bit of a slow dance with a time complexity
of [linear time complexity](https://medium.com/@ariel.salem1989/an-easy-to-use-guide-to-big-o-time-complexity-5dcf4be8a444#:~:text=O(N)%E2%80%94Linear%20Time)
*O(n)*. When you're working with big data, you don't want to be caught slow-shifting. So, we roll up our sleeves and
craft a Queue that's got a speedy [constant time complexity](https://medium.com/@ariel.salem1989/an-easy-to-use-guide-to-big-o-time-complexity-5dcf4be8a444#:~:text=O(1)%20%E2%80%94%20Constant%20Time) O(1) Queue.enqueue(), a snappy O(1) Queue.dequeue(), and a lightning-fast O(1)
Queue.getAt(). Yep, it's Queue-tastic!
<table>
<thead>
<tr><th>Data Structure</th><th>Enqueue Time Complexity</th><th>Dequeue Time Complexity</th><th>Element Access Time Complexity</th><th>Enqueue & Dequeue for 100000 elements</th><th>Access for 100000 elements</th></tr>
<tr><th>Data Structure</th><th>Enqueue</th><th>Dequeue</th><th>Access</th><th>Enqueue & Dequeue 100000</th><th>Access 100000</th></tr>
</thead>
<tbody>
<tr><td>Queue</td><td>O(1)</td><td>O(1)</td><td>O(1)</td><td>22.60ms</td><td>10.60ms</td></tr>
<tr><td>Queue Typed</td><td>O(1)</td><td>O(1)</td><td>O(1)</td><td>22.60ms</td><td>10.60ms</td></tr>
<tr><td>JavaScript Native Array</td><td>O(1)</td><td>O(n)</td><td>O(1)</td><td>931.10ms</td><td>8.60ms</td></tr>

@@ -18,2 +25,3 @@ <tr><td>Other Queue</td><td>O(1)</td><td>O(1)</td><td>O(n)</td><td>28.90ms</td><td>17175.90ms</td></tr>

## more data structures
This is a standalone Queue data structure from the data-structure-typed collection. If you wish to access more data

@@ -40,2 +48,3 @@ structures or advanced features, you can transition to directly installing the

### methods
Queue

@@ -42,0 +51,0 @@ ![](https://github.com/zrwusa/assets/blob/master/images/data-structure-typed/methods-8bit/array-queue.png?raw=true)

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc