码迷,mamicode.com
首页 >  
搜索关键字:pair    ( 2800个结果
indeed 5.13 第二次网测
题目描述,我找不见了,大概写一下想法和代码吧。 1. 没有看 2. 由于数据范围很小,就是简单的枚举,求全排列,然后更新答案。 1 #include<bits/stdc++.h> 2 #define pb push_back 3 typedef long long ll; 4 using names ...
分类:其他好文   时间:2017-05-16 14:51:40    阅读次数:209
[洛谷201704R1]开心派对小火车
OJ题号:洛谷P3697 思路: 贪心。首先从起点出发,开特急电车,对于每一个特急车站$s_{i}$,分别下一次车,计算从当前车站$s_{i}$出发坐各停电车在指定时限内$t$最远能够到达的车站$r_{i}$,并保证这个$r_{i}$不会超过$s_{i+1}$。将得到的站点$r_{i}$放入一个大根 ...
分类:其他好文   时间:2017-05-14 20:32:58    阅读次数:198
261. Graph Valid Tree
题目: Given n nodes labeled from 0 to n - 1 and a list of undirected edges (each edge is a pair of nodes), write a function to check whether these edges ...
分类:其他好文   时间:2017-05-14 13:50:49    阅读次数:206
AVLTree的实现算法(C++实现)
#include<stack> #include<utility> #include<allocators> #include<functional> using std::pair; using std::allocator; using std::less; using std::stack; ...
分类:编程语言   时间:2017-05-14 10:40:06    阅读次数:216
chrome浏览器被reimage pair 劫持怎么处理
不知道什么原因chrome浏览器被reimage pair劫持了,只要在浏览器内部一按回车,就马上进入了reimage pair下载的界面。 在网上找了很多解决方法,最后才在google的chrome官网上找到了解决方案:其实也很简单,就是: 详见网址: https://support.google ...
分类:其他好文   时间:2017-05-12 21:59:22    阅读次数:146
【转】MongoDB配置文件说明
启动MongoDB有2种方式,一是直接指定配置参数,二是指定配置文件。这里先介绍配置文件,启动方式如下: 配置如下:verbose:日志信息冗余。默认false。提高内部报告标准输出或记录到logpath配置的日志文件中。要启用verbose或启用verbosity 用vvvv参数,如: ps:启动 ...
分类:数据库   时间:2017-05-12 17:23:55    阅读次数:212
hdu5386 棋盘涂色模拟
http://acm.hdu.edu.cn/showproblem.php?pid=5386 Problem Description You have an n?n matrix.Every grid has a color.Now there are two types of operating: ...
分类:其他好文   时间:2017-05-10 11:26:42    阅读次数:258
超超超简单的bfs——POJ-1915
Knight Moves Time Limit: 1000MS Memory Limit: 30000K Total Submissions: 26102 Accepted: 12305 Description Background Mr Somurolov, fabulous chess-game ...
分类:其他好文   时间:2017-05-09 21:46:21    阅读次数:183
1010. Radix (25)(进制 + 二分 + 模拟)
Given a pair of positive integers, for example, 6 and 110, can this equation 6 = 110 be true? The answer is "yes", if 6 is a decimal number and 110 is ...
分类:其他好文   时间:2017-05-08 23:29:32    阅读次数:344
需要注意的-----未完待续
1、 queue<pair<int,int> >p; 当我想把这样一个元素取出时,赋值给什么类型的变量呢。 typedef pair<int,int> pii; 在主函数前写个这个.... pii 的位置你随便写什么都行 可以不是pii pii x=q2.front(); 然后定义一个pii类型的x ...
分类:其他好文   时间:2017-05-08 23:12:49    阅读次数:142
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!