# stack vs queue ###### tags: `java` | | stack | queue | |:---------------:|:--------------------------------:|:--------------------------------------------------:| | implement | Stack implement Vector | LinkedList,ArrayList,PriorityQueue implement Queue | | InOut | FILO | FIFO | | peek | peek(),throw StackEmpty if empty | peek(), return null if empty | | remove 1st node | pop(),throw StackEmpty if empty | poll(), return null if empty | | add | add(el) | offer(el) |
×
Sign in
Email
Password
Forgot password
or
By clicking below, you agree to our
terms of service
.
Sign in via Facebook
Sign in via Twitter
Sign in via GitHub
Sign in via Dropbox
Sign in with Wallet
Wallet (
)
Connect another wallet
New to HackMD?
Sign up