自定义博客皮肤VIP专享

*博客头图:

格式为PNG、JPG,宽度*高度大于1920*100像素,不超过2MB,主视觉建议放在右侧,请参照线上博客头图

请上传大于1920*100像素的图片!

博客底图:

图片格式为PNG、JPG,不超过1MB,可上下左右平铺至整个背景

栏目图:

图片格式为PNG、JPG,图片宽度*高度为300*38像素,不超过0.5MB

主标题颜色:

RGB颜色,例如:#AFAFAF

Hover:

RGB颜色,例如:#AFAFAF

副标题颜色:

RGB颜色,例如:#AFAFAF

自定义博客皮肤

-+

Acer12138的博客

早起的鸟儿有虫吃

  • 博客(20)
  • 收藏
  • 关注

原创 [HDU--2586] How far away ? 倍增LCA

Problem DescriptionThere are n houses in the village and some bidirectional roads connecting them. Every day peole always like to ask like this “How far is it if I want to go from house A to house B...

2018-08-24 16:28:04 226

原创 Manacher 学习

先来一段代码压压惊:#include <cstdio>#include <iostream>#include <cstring>#include <algorithm>using namespace std;const int maxn = 1e5+5;char str[maxn],

2018-08-19 09:28:23 208

原创 Ultra-QuickSort (利用归并排序求逆序数)

In this problem, you have to analyze a particular sorting algorithm. The algorithm processes a sequence of n distinct integers by swapping two adjacent sequence elements until the sequence is sorted i...

2018-08-18 19:56:28 241

原创 HDU -- Cyclic Nacklace [kmp]

Problem DescriptionCC always becomes very depressed at the end of this month, he has checked his credit card yesterday, without any surprise, there are only 99.9 yuan left. he is too distressed and ...

2018-08-18 19:48:31 195

原创 Aggressive cows [二分]

Describe有一个神奇的盒子,它有N (2 <= N <= 1e5)个空间,这些空间依次编号为a1,…,aN (0 <= ai <= 1e9). 有x (2 <= x <= N)巧克力,如果多个巧克力放在一个空间就会爆炸。为了不让巧克力爆炸。我们需要使任意两个巧克力之间的最小距离尽可能的大,那么,这个最大的最小距离是什么呢?Input有多组测试数...

2018-08-17 22:20:46 367

原创 POJ--3667 Hotel

HotelDescriptionThe cows are journeying north to Thunder Bay in Canada to gain cultural enrichment and enjoy a vacation on the sunny shores of Lake Superior. Bessie, ever the competent travel agen...

2018-08-17 14:24:50 342

原创 Dragon Balls

题意: 五百年后,龙珠的数量会出乎意料地增加,因此孙悟空(吴)将所有的龙球聚集在一起太难了。 他的国家有N个城市,世界上正好有N个龙球。起初,对于第i个龙球,神圣的龙将把它放在第i个城市。长年以来,一些城市的龙球将被运往其他城市。为了挽救体力,吴孔计划采用飞行云中云,一种神奇的飞云收集龙珠。 每次武功收集一个龙球的信息,他都会问你那个球的信息。你必须告诉他球在哪个城市以及那个城市有多少个...

2018-08-15 23:05:17 410

原创 Popular Cows

Description Every cow’s dream is to become the most popular cow in the herd. In a herd of N (1 <= N <= 10,000) cows, you are given up to M (1 <= M <= 50,000) ordered pairs of the form (A,...

2018-08-15 20:58:55 172

原创 Tunnel Warfare [HDU--1540]

Problem Description During the War of Resistance Against Japan, tunnel warfare was carried out extensively in the vast areas of north China Plain. Generally speaking, villages connected by tunnels la...

2018-08-15 13:55:54 182

原创 C. Vasya And The Mushrooms【codeforces】

Vasya’s house is situated in a forest, and there is a mushroom glade near it. The glade consists of two rows, each of which can be divided into n consecutive cells. For each cell Vasya knows how fast ...

2018-08-11 20:14:32 352

原创 LIS && LCS

LCS最长公共子序列,大神博客 在这里不再 一 一 赘述LCS,如果为小白请参见链接, 接下来谈一下LCS的路径回溯问题LIS最长上升子序列, 大神博客...

2018-08-09 21:29:05 1014

原创 背包专题

01背包01背包是所有背包的基础,很重要也很基础而且最重要的是有很多变形,能够运用得非常灵活,网上有很好的介绍01背包的博客我在这里就不写他的原理和详细步骤了,只是转载一下他们的博客,包括下面的完全背包,多维背包 等等,我想写这篇博客的主要目的是介绍背包的用法,当然了转载的博客是很基础的,因此小白也可以来看 01背包详解 01背包的运用很广泛,也很灵活但是表现在哪里呢看下这道题10...

2018-08-08 16:51:03 273

原创 Longest Increasing Subsequence (第三次积分赛)

描述 给出一组长度为n的序列,a1a2a3......ana1a2a3......ana_{1}a_{2}a_{3} ...... a_{n}求出这个序列长度为kk的严格递增子序列的个数输入 第一行输入T组数据 T (0≤T≤10) 第二行输入序列大小n(1≤n≤100),长度k(1≤k≤n) 第三行输入n个数字输出 数据规模很大, 答案请对1e9+7取模输入样例 1 2...

2018-08-06 16:30:58 161

原创 Multivariate function (第三次积分赛)

Multivariate function 描述 输入 第一行一个整数T,表示T组测试数据 (1≤T≤10). 每组数据第一行一个整数n(4≤n≤1000). 第二行 n个浮点数: X1,X2X3......Xn(1<=Xi<=1000000)X1,X2X3......Xn(1<=Xi<=1000000)X_{1} , X_{2}X_{3}......X_{n...

2018-08-06 12:07:40 238

原创 poj- 2528 Mayor's posters

Mayor’s postersDescriptionThe citizens of Bytetown, AB, could not stand that the candidates in the mayoral election campaign have been placing their electoral posters at all places at their whim. ...

2018-08-05 21:08:27 168

原创 POJ 2631 Roads in the North (树的直径裸题)

Description Building and maintaining roads among communities in the far North is an expensive business. With this in mind, the roads are build such that there is only one route from a village to a vi...

2018-08-05 09:39:38 228

原创 Quoit Design (白话--分治--平面点对问题)

Quoit DesignProblem DescriptionHave you ever played quoit in a playground? Quoit is a game in which flat rings are pitched at some toys, with all the toys encircled awarded. In the field of Cyb...

2018-08-04 20:09:32 876

原创 洛古 P1020 导弹拦截 (贪心+二分)

题目描述 某国为了防御敌国的导弹袭击,发展出一种导弹拦截系统。但是这种导弹拦截系统有一个缺陷:虽然它的第一发炮弹能够到达任意的高度,但是以后每一发炮弹都不能高于前一发的高度。某天,雷达捕捉到敌国的导弹来袭。由于该系统还在试用阶段,所以只有一套系统,因此有可能不能拦截所有的导弹。 输入导弹依次飞来的高度(雷达给出的高度数据是 ≤50000 \le 50000≤50000 的正整数),计算这套系统...

2018-08-02 15:43:26 344

原创 D - How Many Equations Can You Find (玄学)

Now give you an string which only contains 0, 1 ,2 ,3 ,4 ,5 ,6 ,7 ,8 ,9.You are asked to add the sign ‘+’ or ’-’ between the characters. Just like give you a string “12345”, you can work out a string ...

2018-08-01 22:30:51 234

原创 POJ - 2227 Count Color

Count ColorDescription Chosen Problem Solving and Program design as an optional course, you are required to solve all kinds of problems. Here, we get a new problem. There is a very long board wit...

2018-08-01 11:24:18 181

空空如也

空空如也

TA创建的收藏夹 TA关注的收藏夹

TA关注的人

提示
确定要删除当前文章?
取消 删除