• *HDU 1054 二分图

    时间:2024-05-12 22:15:15

    Strategic GameTime Limit: 20000/10000 MS (Java/Others)    Memory Limit: 65536/32768 K (Java/Others)Total Submission(s): 7651    Accepted Submission(s)...

  • hdu 1229 超级大水题

    时间:2024-05-12 15:05:30

    Time Limit: 1000MS Memory Limit: 32768KB 64bit IO Format: %I64d & %I64uSubmit StatusDescription读入两个小于10000的正整数A和B,计算A+B。需要注意的是:如果A和B的末尾K(不超过8)位数字相...

  • HDU 2292

    时间:2024-05-11 18:27:46

    http://acm.hdu.edu.cn/showproblem.php?pid=2292题意:1-n个节点,题目给出了完全二叉树的定义(这个定义似乎有歧义,此题以题目描述为准),且要保持最小堆性质(根节点小于左右子树内的任意元素),问有多少种不同组合解法:dp,dp[n]表示n个元素的合法排列数...

  • hdu 5625 Clarke and chemistry

    时间:2024-05-11 10:36:47

    Problem DescriptionClarke is a patient with multiple personality disorder. One day, Clarke turned into a junior student and took a chemistry exam.  Bu...

  • HDU 2829 Lawrence(四边形优化DP O(n^2))

    时间:2024-05-10 13:43:17

    题目链接:http://acm.hdu.edu.cn/showproblem.php?pid=2829题目大意:有一段铁路有n个站,每个站可以往其他站运送粮草,现在要炸掉m条路使得粮草补给最小,粮草补给的公式是将每个站能收到的粮草的总和。4----5-----1-----2粮草总和为4*5 + 4*...

  • 【HDU】2147 kiki's game

    时间:2024-05-09 21:28:03

    http://acm.hdu.edu.cn/showproblem.php?pid=2147题意:n×m的棋盘,每次可以向左走、向下走、向左下走,初始在(1, m),n,m<=2000,问先手是否胜利。#include <cstdio>using namespace std;int...

  • HDU 5558 后缀数组+二分

    时间:2024-05-09 18:18:57

    题意有一些绕,但其实就是对于不断变化的i,求以j(0=j<i)使得suffix[j]与suffix[i]的最长公共前缀最长,如果有多个j,则取最小的j。可以在rank数组中二分,在1-rank[i-1]中二分最接近i的j使得sa[j]小于i,通俗地说就是rank比的rank[i]小,并且位于i...

  • HDU3376 最小费用最大流 模板2

    时间:2024-05-09 18:13:17

    Matrix AgainTime Limit: 5000/2000 MS (Java/Others)    Memory Limit: 102400/102400 K (Java/Others)Total Submission(s): 4255    Accepted Submission(s): ...

  • HDU 2144 (最长连续公共子列 + 并查集) Evolution

    时间:2024-05-08 23:09:41

    我发现我一直理解错题意了,这里的子序列指的是连续子序列,怪不得我写的LCS一直WA顺便复习一下并查集 //#define LOCAL #include <iostream> #include <cstdio> #include <cstring> #include...

  • hdu 5438 Ponds dfs

    时间:2024-05-05 18:59:51

    Time Limit: 1500/1000 MS (Java/Others)    Memory Limit: 131072/131072 K (Java/Others)Problem DescriptionBetty owns a lot of ponds, some of them are co...

  • HDU 2162 Add ‘em

    时间:2024-05-04 13:39:38

    http://acm.hdu.edu.cn/showproblem.php?pid=2162Problem DescriptionWrite a program to determine the summation of several sets of integers.InputThe input...

  • hdu 5335 Walk Out(bfs+寻找路径)

    时间:2024-05-03 19:03:17

    Problem DescriptionIn an n∗m maze, the right-bottom corner is the exit (position (n,m) is the exit). In every position of this maze, there is either a...

  • HDOJ(HDU) 1898 Sempr == The Best Problem Solver?(水题、、、)

    时间:2024-05-03 10:05:56

    Problem Description As is known to all, Sempr(Liangjing Wang) had solved more than 1400 problems on POJ, but nobody know the days and nights he had sp...

  • HDU 5547 Sudoku(DFS)

    时间:2024-05-02 10:38:09

    题目网址:http://acm.hdu.edu.cn/showproblem.php?pid=5547题目:SudokuTime Limit: 3000/1000 MS (Java/Others)    Memory Limit: 65535/65535 K (Java/Others)Total S...

  • HDU 4828 (卡特兰数+逆)

    时间:2024-05-01 23:36:42

    HDU 4828 Grids思路:能够转化为卡特兰数,先把前n个人标为0。后n个人标为1。然后去全排列,全排列的数列。假设每一个1的前面相应的0大于等于1,那么就是满足的序列,假设把0看成入栈,1看成出栈。那么就等价于n个元素入栈出栈,求符合条件的出栈序列,这个就是卡特兰数了。然后去递推一下解,过程...

  • HDU 5762 Teacher Bo (暴力)

    时间:2024-05-01 10:39:41

    Teacher Bo题目链接:http://acm.hdu.edu.cn/showproblem.php?pid=5762DescriptionTeacher BoBo is a geography teacher in the school.One day in his class,he mark...

  • hdu 4850 Wow! Such String!(字符串处理,yy)

    时间:2024-04-30 13:02:29

    题目参考了博客http://blog.csdn.net/u013368721/article/details/37575165//用visit[26][26][26][26]来判断新家新区的子母河前三个组合而成的4个字符的串是否和之前的重复。//再加上最初三个字符,所以,总共有26*26*26*26...

  • hdu 5739 割点

    时间:2024-04-29 21:41:04

    FantasiaTime Limit: 10000/5000 MS (Java/Others)    Memory Limit: 65536/65536 K (Java/Others)Total Submission(s): 1654    Accepted Submission(s): 429Pr...

  • HDU 1525 Euclid's Game

    时间:2024-04-28 16:36:43

    题目大意:题目给出了两个正数a.b每次操作,大的数减掉小的数的整数倍。一个数变为0 的时候结束。谁先先把其中一个数减为0的获胜。问谁可以赢。Stan是先手。题目思路:无论a,b的值为多少,局面:[a%b,b] 一定会出现。双方都足够聪明,无论谁都知道这种局面是必胜局面还是必败局面若是必败局面操作者为...

  • 2010多校第一题 hdu3440House Man 差分约束系统

    时间:2024-04-28 09:46:40

    给我们n座房子,房子的高度各不相同, 从最低的房子开始, 每次跳到更高的房子, 跳n-1次最能跳到最高的房子了,但是每次跳跃的距离不能超过d将这些房子在一维的方向上重新摆放(但是保持输入时的相对位置不变) , 使得最矮的房子和最高的房子水平距离最大将房子的坐标设为xi,  n个变量, 和2(n-1)...