Created
November 13, 2021 21:13
-
-
Save kleinron/fdeedb03d75bc9a25992bf3518bb220c to your computer and use it in GitHub Desktop.
queue interface
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
interface Queue extends Iterable<any>{ | |
enqueue(item: any): void; | |
dequeue(): any; | |
clear(): void; | |
size(): number; | |
peekFirst(): any; | |
peekLast(): any; | |
copyTo(arr: any[], startIndex?: number): void | |
drainingIterator(): Iterator<any>; | |
toJSON(): any[]; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment