摘要: http://acm.split.hdu.edu.cn/showproblem.php?pid=2255 带权匹配问题: #include <stdio.h> #include <algorithm> #include <string.h> #include <vector> using names 阅读全文
posted @ 2016-08-22 15:48 不忧尘世不忧心 阅读(99) 评论(0) 推荐(0) 编辑
摘要: http://acm.nyist.net/JudgeOnline/problem.php?pid=1261 分析:若是每次都想用sort继而来查第k个数,那会T的特别惨~ C++内置函数upperbound(查找数组的首地址, 查找数组的尾地址, 待查找元素)为logn复杂度的二分查找, 返回第一个 阅读全文
posted @ 2016-08-22 09:29 不忧尘世不忧心 阅读(153) 评论(0) 推荐(0) 编辑