Skip to content

Commit

Permalink
Updated README
Browse files Browse the repository at this point in the history
  • Loading branch information
zimmed committed Aug 13, 2021
1 parent 9717601 commit 18d46a5
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -143,7 +143,7 @@ A simple FIFO or LIFO Queue datastructure, using the SizedLinkedList prefab.
```typescript
import { Queue } from '@zimmed/prefab';

const queue = Queue.from([1, 2, 3], Queue.Type.FIFO);
const queue = Queue.from([1, 2, 3]);
const stack = Queue.from([1, 2, 3], Queue.Type.LIFO);

queue.enqueue(4).add(3); // -> Queue { 1 2 3 4 3 }
Expand All @@ -169,7 +169,7 @@ common vocabulary one would expect for a Queue datastructure (unique elements on
```typescript
import { UniQueue as Queue } from '@zimmed/prefab';

const q = Queue.from([1, 2, 3, 4, 4, 3], Queue.Type.FIFO); // -> UniQueue { 1, 2, 3, 4 }
const q = Queue.from([1, 2, 3, 4, 4, 3]); // -> UniQueue { 1, 2, 3, 4 }

q.has(3); // -> Hashmap lookup time
```
Expand Down

0 comments on commit 18d46a5

Please sign in to comment.