码迷,mamicode.com
首页 > 其他好文 > 详细

什么是MinPQ

时间:2020-03-27 01:05:40      阅读:192      评论:0      收藏:0      [点我收藏+]

标签:imu   ini   zed   class   code   eric   tin   max   pac   

今天看《算法》图论的最小生成树部分,里面有一行代码不是很理解

private MinPQ<Edge> pq;

上中文互联网上没查到资料,去外网查了一下。

The MinPQ class represents a priority queue of generic keys. It supports the usual insert and delete-the-minimum operations, along with methods for peeking at the maximum key, testing if the priority queue is empty, and iterating through the keys.
The insert and delete-the-minimum operations take logarithmic amortized time. The min, size, and is-empty operations take constant time. Construction takes time proportional to the specified capacity or the number of items used to initialize the data structure.
This implementation uses a binary heap.

翻译就不做了,相信学计算机的这点英文还是有的。

什么是MinPQ

标签:imu   ini   zed   class   code   eric   tin   max   pac   

原文地址:https://www.cnblogs.com/endevelop-gw/p/12578554.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!