Skip to main content
 首页 » 编程设计

java固定长度的队列

2022年07月18日46dflying
public static void main(String[] args) throws InterruptedException {
CircularFifoQueue queue = new CircularFifoQueue(5);
for(int i = 0;i < 10;i++) {
queue.add(i);
System.out.print(queue);
Thread.sleep(2000);
}
}

参考:https://yuanmomo.net/2019/06/25/java-fixed-queue/

https://blog.csdn.net/liuxiao723846/article/details/81782507

https://my.oschina.net/MStart/blog/518216

本文参考链接:https://www.cnblogs.com/maohuidong/p/15272317.html