码迷,mamicode.com
首页 >  
搜索关键字:pair    ( 2800个结果
Leetcode-5213 Play with Chips(玩筹码)
1 typedef long long ll; 2 typedef pair<int,int> P; 3 #define _for(i,a,b) for(register int i = (a);i < b;i ++) 4 #define _rep(i,a,b) for(register int i... ...
分类:其他好文   时间:2019-10-06 15:14:33    阅读次数:58
Leetcode-5214 Longest Arithmetic Subsequence of Given Difference(最长定差子序列)
1 typedef long long ll; 2 typedef pair<int,int> P; 3 #define _for(i,a,b) for(register int i = (a);i < b;i ++) 4 #define _rep(i,a,b) for(register int i... ...
分类:其他好文   时间:2019-10-06 15:10:43    阅读次数:74
Leetcode-5215 Path with Maximum Gold(黄金矿工)
1 typedef long long ll; 2 typedef pair<int,int> P; 3 #define _for(i,a,b) for(register int i = (a);i < b;i ++) 4 #define _rep(i,a,b) for(register int i... ...
分类:其他好文   时间:2019-10-06 15:05:38    阅读次数:69
Leetcode-5216 Count Vowels Permutation(统计元音字母序列的数目)
1 typedef long long ll; 2 typedef pair P; 3 #define _for(i,a,b) for(register int i = (a);i b;i --) 5 #define INF 0x3f3f3f3f 6 #define MOD 1000000007 7... ...
分类:其他好文   时间:2019-10-06 15:02:05    阅读次数:77
求一个数的最少的完全平方数之和等于本身的完全平方数的数量
class Solution { public: int numSquares(int n) { queue<pair<int, int> > pq; //队列中放置一组数据 vector<bool> used(n + 1, false); pq.push(make_pair(n, 0)); whi... ...
分类:其他好文   时间:2019-10-06 00:30:34    阅读次数:214
bzoj2325 [ZJOI2011]道馆之战 树链剖分+DP+类线段树最大字段和
bzoj2325 [ZJOI2011]道馆之战。 树链剖分+DP+类线段树最大字段和 ...
分类:其他好文   时间:2019-10-05 22:46:17    阅读次数:110
定根最小树形图 朱刘算法 luogu P4716
https://www.luogu.org/problem/P4716 ...
分类:编程语言   时间:2019-10-05 20:03:30    阅读次数:98
[CSP-S模拟测试]:凤凰院凶真(LCIS)
题目描述 $\alpha$世界线。凤凰院凶真创立了反抗$SERN$统治的组织“瓦尔基里”。为了脱离$\alpha$线,他需要制作一个世界线变动率测量仪。测量一个世界线相对于另一个世界线的变动率,实质上就是要求出这两个世界线的最长公共合法事件序列。一个世界线的事件逻辑序列是一个正整数序列,第$k$个数 ...
分类:其他好文   时间:2019-10-05 18:03:51    阅读次数:91
进程间通信效率测试
"来源" Type These are kinds of IPC in Linux as the following: type|feature | |: : pipe|unnamed pipe fifo|named pipe socketpair | unnamed unix domain soc ...
分类:系统相关   时间:2019-10-05 10:50:03    阅读次数:241
C++ pair(对组)用法
1,pair的应用 pair是将2个数据组合成一组数据,当需要这样的需求时就可以使用pair,如stl中的map就是将key和value放在一起来保存。另一个应用是,当一个函数需要返回2个数据的时候,可以选择pair。 pair的实现是一个结构体,主要的两个成员变量是first second 因为是 ...
分类:编程语言   时间:2019-10-05 10:43:43    阅读次数:185
2800条   上一页 1 ... 57 58 59 60 61 ... 280 下一页
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!