Java是否有索引的最低优先级队列? [英] Does java have an indexed minimum priority queue?

查看:82
本文介绍了Java是否有索引的最低优先级队列?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我需要它来实现Dijkstra的算法,并且确实有我自己的实现,但是使用Java自己的类对我的代码进行文档记录会更容易。

I need it for an implementation of Dijkstra's algorithm, and I do have my own implementation but documenting my code would be easier with java's own classes.

推荐答案

否,Java标准库没有这样的数据结构。
我想大多数人都使用这个:
http:// algs4.cs.princeton.edu/24pq/IndexMinPQ.java.html

No, Java standard library has no such data structure. I think most people use this: http://algs4.cs.princeton.edu/24pq/IndexMinPQ.java.html

这篇关于Java是否有索引的最低优先级队列?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆