优先队列(priority_queue)的cmp,POJ(2051)

sort()函数的cmp为函数,priority_queue的cmp为类,具体写法是: struct Node {   int i,j; } node[200]; struct cmp { bool operator() (Node a,Node b) { if(a.i==b.i) return a.j<b.j;///j的升序
相关文章
相关标签/搜索