Created
May 15, 2019 08:14
-
-
Save erlangparasu/945f21d757b7857c76b462defab76627 to your computer and use it in GitHub Desktop.
This file contains hidden or 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
| val queue = CircularFifoQueue<String>(5) | |
| queue.add("a") | |
| queue.add("b") | |
| queue.add("c") | |
| queue.add("d") | |
| queue.add("e") | |
| queue.add("f") | |
| queue.add("g") | |
| queue.add("h") | |
| queue.add("i") | |
| for (item in queue) { | |
| System.out.println(item) | |
| } | |
| // Output: | |
| // e | |
| // f | |
| // g | |
| // h | |
| // i |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment