码迷,mamicode.com
首页 >  
搜索关键字:pair    ( 2800个结果
Gym - 101806R :Recipe(分治+斜率优化)
#include #define pii pair #define mp make_pair #define ll long long #define rep(i,a,b) for(int i=a;i>1; ll tmp1=getans(p,q[Mid]),tmp2=getans(p,q[Mid+1... ...
分类:其他好文   时间:2019-02-06 11:58:40    阅读次数:179
#7:怀念儿时的春节——9
CF618C,水啊。 1 #include <bits/stdc++.h> 2 #define ll long long 3 using namespace std; 4 5 struct point { 6 ll x, y; 7 int id; 8 bool operator < (const p ...
分类:其他好文   时间:2019-02-06 09:27:29    阅读次数:104
luoguP3366 [模板] 最小生成树
题目链接:https://www.luogu.org/problemnew/show/P3366 思路: 求最小生成树的模板题,求MST有两种算法——Prim、Kruskal。 两者区别:Prim在稠密图中比Kruskal优,在稀疏图中比Kruskal劣。Prim是以更新过的节点的连边找最小值,Kr ...
分类:其他好文   时间:2019-02-05 13:05:34    阅读次数:229
STL——pair
功能:pair将一对值组合成一个值,这一对值可以具有不同的数据类型(T1和T2),两个值可以分别用pair的两个公有函数first和second访问。 ...
分类:其他好文   时间:2019-02-04 18:16:54    阅读次数:157
POJ3481 Double Queue
1 #include 2 #include 3 #include 4 #include 5 using namespace std; 6 int flag=1; 7 typedef pair p; 8 typedef set::iterator setit; 9 set s; 10 int main... ...
分类:其他好文   时间:2019-02-04 01:04:26    阅读次数:208
PAT 甲级 1010 Radix
https://pintia.cn/problem-sets/994805342720868352/problems/994805507225665536 Given a pair of positive integers, for example, 6 and 110, can this equa ...
分类:其他好文   时间:2019-02-03 21:01:13    阅读次数:126
CF2A Winner
题目描述: 在 Berland 流行着纸牌游戏 “Berlogging” ,这个游戏的赢家是根据以下规则确定的:在每一轮中,玩家获得或失去一定数量的分数,在游戏过程中,分数被记录在“名称和得分”行中,其中名称是玩家的名字,得分是在这一轮中获得的分数。得分是负值意味着玩家失去了相应的分数。如果在比赛结 ...
分类:Windows程序   时间:2019-02-03 10:31:07    阅读次数:185
PAT A1063——set的常见用法详解
1063 Set Similarity Given two sets of integers, the similarity of the sets is defined to be N?c??/N?t??×100%, where N?c?? is the number of distinct co ...
分类:其他好文   时间:2019-02-02 14:36:12    阅读次数:163
【AtCoder】CODE FESTIVAL 2017 qual C
A Can you get AC? No cpp include define fi first define se second define pii pair define pb push_back define mp make_pair using namespace std; typedef ...
分类:其他好文   时间:2019-02-01 22:35:30    阅读次数:161
CFB. New Year and the Treasure Geolocation贪心!
这题啊哈哈哈哈哈哈哈哈哈 简单的不行,但是为什么我要说呢 因为这是我打的第一场CF,看到这题就吓得飞出去了 这题...直接把前n行的最大的pair 加上后n行里最小的pair即可 因为最后是要归于同一个点 或者还有个方法,就是把前n行的pair和后n行的pair全部叠加,再除个n 这是为啥呢,因为归 ...
分类:其他好文   时间:2019-02-01 19:50:01    阅读次数:247
2800条   上一页 1 ... 85 86 87 88 89 ... 280 下一页
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!