01 2020 档案
D - Counting Squares
摘要:Your input is a series of rectangles, one per line. Each rectangle is specified as two points(X,Y) that specify the opposite corners of a rectangle. A 阅读全文
posted @ 2020-01-31 17:33 带你AK,带你飞 阅读(183) 评论(0) 推荐(0)
POJ 3617 Best Cow Line 贪心
摘要:Best Cow Line Time Limit: 1000MS Memory Limit: 65536K Total Submissions: 46960 Accepted: 11949 Description FJ is about to take his N (1 ≤ N ≤ 2,000) c 阅读全文
posted @ 2020-01-31 12:01 带你AK,带你飞 阅读(113) 评论(0) 推荐(0)
POJ 3984 迷宫问题
摘要:迷宫问题 Time Limit: 1000MS Memory Limit: 65536K Total Submissions: 49149 Accepted: 26684 Description 定义一个二维数组: int maze[5][5] = { 0, 1, 0, 0, 0, 0, 1, 0, 阅读全文
posted @ 2020-01-31 10:20 带你AK,带你飞 阅读(225) 评论(0) 推荐(0)
POJ-2386 Lake Counting
摘要:Lake Counting Time Limit: 1000MS Memory Limit: 65536K Total Submissions: 56258 Accepted: 27405 Description Due to recent rains, water has pooled in va 阅读全文
posted @ 2020-01-31 08:56 带你AK,带你飞 阅读(105) 评论(0) 推荐(0)
白书-部分和问题
摘要:部分和问题时间限制:1000 ms | 内存限制:65535 KB难度:2描述给定整数a1、a2、.......an,判断是否可以从中选出若干数,使它们的和恰好为K。输入首先,n和k,n表示数的个数,k表示数的和。接着一行n个数。(1<=n<=20,保证不超int范围)输出如果和恰好可以为k,输出“ 阅读全文
posted @ 2020-01-31 08:36 带你AK,带你飞 阅读(115) 评论(0) 推荐(0)
STL-map/multimap 简述
摘要:1 #include <iostream> 2 #include <cstdio> 3 #include <map> 4 5 using namespace std; 6 7 8 int main() 9 { 10 // map && multimap 11 // 键值映射容器,一对一,一对多 12 阅读全文
posted @ 2020-01-30 11:43 带你AK,带你飞 阅读(139) 评论(0) 推荐(0)
STL-set&&multiset 集合
摘要:1 #include <iostream> 2 #include <cstdio> 3 #include <set> 4 5 // 仿函数的原型 6 //struct greaters 7 //{ 8 // bool operator()(const int &left,const int &rig 阅读全文
posted @ 2020-01-30 11:11 带你AK,带你飞 阅读(131) 评论(0) 推荐(0)
STL-优先级队列-priority_queue
摘要:头文件是<queue> 操作很简单 #include <iostream> #include <cstdio> #include <queue> using namespace std; int main() { // 默认定义最大值优先级队列 priority_queue<int> p1; p1. 阅读全文
posted @ 2020-01-29 20:14 带你AK,带你飞 阅读(134) 评论(0) 推荐(0)
挣脱虚无,化身虚无
摘要:永远不要让心灵干涸,时刻拥有着梦想,体验着人生,拥有着思想,做出行动,做让自己骄傲的事,做让世界变得更美好的事。 如今,要如树的种子般,扎根大地,深深的汲取让自己爆发的力量。 化身虚无,如同从未出现过一样。悄然的改变着世界,做着自己所能做出的贡献,而不留下痕迹。 “技术无黑白,攻防无对错”,也许,作 阅读全文
posted @ 2020-01-29 19:57 带你AK,带你飞 阅读(152) 评论(0) 推荐(0)
C - Beautiful Now
摘要:Anton has a positive integer nn, however, it quite looks like a mess, so he wants to make it beautiful after kk swaps of digits. Let the decimal repre 阅读全文
posted @ 2020-01-29 11:40 带你AK,带你飞 阅读(158) 评论(0) 推荐(0)
B - Draw!
摘要:You still have partial information about the score during the historic football match. You are given a set of pairs (ai,bi)(ai,bi), indicating that at 阅读全文
posted @ 2020-01-29 09:09 带你AK,带你飞 阅读(141) 评论(0) 推荐(0)
A - Kvass and the Fair Nut 二分
摘要:The Fair Nut likes kvass very much. On his birthday parents presented him nn kegs of kvass. There are vivi liters of kvass in the ii-th keg. Each keg 阅读全文
posted @ 2020-01-28 22:01 带你AK,带你飞 阅读(163) 评论(0) 推荐(0)
STL-list 链表
摘要:1 #include <iostream> 2 #include <list> 3 4 using namespace std; 5 6 int main() 7 { 8 // list可以在头部和尾部插入和删除元素 9 // 不能随机访问元素,迭代器只能++,不能一次性跳转 10 list<int 阅读全文
posted @ 2020-01-28 21:11 带你AK,带你飞 阅读(130) 评论(0) 推荐(0)
STL-queue 队列
摘要:1 #include <iostream> 2 #include <queue> 3 4 using namespace std; 5 6 int main() 7 { 8 // queue也很简单 9 // push,pop,size,front 10 queue<int> q1; 11 q1.p 阅读全文
posted @ 2020-01-28 20:59 带你AK,带你飞 阅读(121) 评论(0) 推荐(0)
STL-stack栈
摘要:1 #include <iostream> 2 #include <stack> 3 4 using namespace std; 5 6 int main() 7 { 8 // 栈比较简单 9 // push,pop,size,top 10 // 基本操作很少,很容易实现和使用 11 // 一般可 阅读全文
posted @ 2020-01-28 20:53 带你AK,带你飞 阅读(117) 评论(0) 推荐(0)
立志 读书
摘要:阅读一本好书,实际上是在阅读你自己。读书,不只是与作者灵魂的交谈,更是与自己心灵的一次对话。你是一个怎么样的人,你想要成为一个怎么样的人,你如何能成为你想要成为的人,在读书中,你都能找到答案。多读书,读好书,好读书。立志,自今日起,每日必读书。 你以为,别人都像你一样,不知努力,殊不知,别人都在努力 阅读全文
posted @ 2020-01-28 20:43 带你AK,带你飞 阅读(194) 评论(0) 推荐(0)
STL-deque 双端数组简析
摘要:1 #include <iostream> 2 #include <deque> 3 4 using namespace std; 5 6 int main() 7 { 8 // 插入 9 deque<int> de; 10 for(int i=0;i<5;++i) 11 { 12 de.push_ 阅读全文
posted @ 2020-01-28 18:52 带你AK,带你飞 阅读(202) 评论(0) 推荐(0)
STL-vector
摘要:1 #include <iostream> 2 #include <cstdio> 3 #include <vector> 4 5 using namespace std; 6 7 // 注意:vector在尾部添加或移动元素非常快,在中间操作非常耗时,因为它需要移动元素 8 9 10 int ma 阅读全文
posted @ 2020-01-28 17:35 带你AK,带你飞 阅读(133) 评论(0) 推荐(0)
STL-string用法
摘要:1 #include <string> 2 #include <iostream> 3 #include <cstring> 4 #include <algorithm> 5 6 using namespace std; 7 8 int to_lower(int c) 9 { 10 if (isup 阅读全文
posted @ 2020-01-28 11:53 带你AK,带你飞 阅读(253) 评论(0) 推荐(0)
写作之因,与君共进共勉
摘要:求学于武汉,今日,由于某些原因,导致了一些不愉快的事情发生,当然,都是小事,但对于自己的情绪,还是带来了一定的影响的。 已过半日,细细想来,不过尔尔。情绪,时好时坏,想要变得更强,想要去往更广阔的天地,人,就必须要学会掌管自己的情绪。用良好的情绪,激励自己,让消极的情绪,烟消云散。心境不同,天差地别 阅读全文
posted @ 2020-01-28 10:24 带你AK,带你飞 阅读(126) 评论(0) 推荐(0)
ACM常用STL容器
摘要:1 // STL(标准模板库),由三大部分组成:容器,算法,迭代器 2 3 4 // STL六大组件:container(容器),algorthm(算法),iterator(迭代器) 5 // function object(仿函数),adaptor(适配器),allocator(空间适配器) 6 阅读全文
posted @ 2020-01-27 18:12 带你AK,带你飞 阅读(176) 评论(0) 推荐(0)
Antenna Placement poj 3020
摘要:Antenna Placement Time Limit: 1000MS Memory Limit: 65536K Total Submissions: 12104 Accepted: 5954 Description The Global Aerial Research Centre has be 阅读全文
posted @ 2020-01-27 17:31 带你AK,带你飞 阅读(131) 评论(0) 推荐(0)
Asteroids
摘要:Time Limit: 1000MS Memory Limit: 65536K Total Submissions: 29547 Accepted: 15807 Description Bessie wants to navigate her spaceship through a dangerou 阅读全文
posted @ 2020-01-27 09:42 带你AK,带你飞 阅读(316) 评论(0) 推荐(0)
12388. 图论割边
摘要:n个顶点m条边,请求割边 输入格式: 第一行给定三个整数 n,m 。n 个城镇,m 条道路(双向道路)。接下来给出 m 行,每行两个正整数表示这两个城镇之间有边相连。 输出格式: 一个整数,有几条关键道路。 样例 1 : 输入:6 6 1 3 1 4 2 3 2 4 2 5 5 6 输出:2 说明: 阅读全文
posted @ 2020-01-26 14:49 带你AK,带你飞 阅读(185) 评论(0) 推荐(0)
12389. 割点
摘要:n个顶点m条边,请求割点 输入格式: 第一行给定三个整数 n,m 。n 个城镇,m 条道路(双向道路)。接下来给出 m 行,每行两个正整数表示这两个城镇之间有边相连。 输出格式: 一个整数,有几个关键城市。 样例 1 : 输入:9 11 1 2 2 3 1 3 3 5 4 3 5 6 4 6 6 8 阅读全文
posted @ 2020-01-26 12:05 带你AK,带你飞 阅读(186) 评论(0) 推荐(0)
12206. 电缆网络
摘要:电话线路公司(TLC)正在建立一个新的电话电缆网络。它们连接了n个位置。每个地方都有一个交换机。电缆是双向的,连接两个地方,电缆每一端都会连接到当地的交换机中。从每一个地方都可以通过电缆连接到其他地方(可以通过其他交换机到达某地,而未必直接连接)。有时有的地方停电导致交换机故障。TLC官员认识到,在 阅读全文
posted @ 2020-01-26 11:11 带你AK,带你飞 阅读(216) 评论(0) 推荐(0)
12178. 破坏牛棚
摘要:约翰意识到贝茜建设网络花费了他巨额的经费,就把她解雇了。贝茜很愤怒,打算狠狠报复。她打算破坏刚建成的约翰的网络。约翰的网络是树形的,连接着N(1≤N≤10000)个牛棚,她打算切断某一个牛棚的电源,使和这个牛棚相连的所有电缆全部中断。之后,就会存在若干子网络。为保证破坏够大,每一个子网的牛棚数不得超 阅读全文
posted @ 2020-01-25 19:49 带你AK,带你飞 阅读(186) 评论(0) 推荐(0)