随笔分类 - OJ-HDU
摘要:Problem Description King OMeGa catched three men who had been streaking in the street. Looking as idiots though, the three men insisted that it was a
阅读全文
摘要:Problem Description There is an apple tree in front of Taotao's house. When autumn comes, n apples on the tree ripen, and Taotao will go to pick these
阅读全文
摘要:Problem Description In computer science, a character is a letter, a digit, a punctuation mark or some other similar symbol. Since computers can only p
阅读全文
摘要:Problem B. Harvest of Apples Problem Description There are n apples on a tree, numbered from 1 to n.Count the number of ways to pick at most m apples.
阅读全文
摘要:Tom和Jerry正在玩一种Northcott游戏,可是Tom老是输,因此他怀疑这个游戏是不是有某种必胜策略,郁闷的Tom现在向你求救了,你能帮帮他么? 游戏规则是这样的: 如图所示,游戏在一个n行m列(1 ≤ n ≤ 1000且2 ≤ m ≤ 100)的棋盘上进行,每行有一个黑子(黑方)和一个白子
阅读全文
摘要:Bomb Game John and Jack, two mathematicians, created a game called “Bomb Game” at spared time. This game is played on an n*m chessboard. A pair of int
阅读全文
摘要:Be the Winner Problem Description Let's consider m apples divided into n groups. Each group contains no more than 100 apples, arranged in a line. You
阅读全文
摘要:S-Nim Problem Description Arthur and his sister Caroll have been playing a game called Nim for some time now. Nim is played as follows: The starting p
阅读全文
摘要:Kiki & Little Kiki 2 Time Limit: 2000/1000 MS (Java/Others) Memory Limit: 32768/32768 K (Java/Others)Total Submission(s): 2915 Accepted Submission(s):
阅读全文
摘要:Chinese Rings Time Limit: 2000/1000 MS (Java/Others) Memory Limit: 32768/32768 K (Java/Others)Total Submission(s): 1221 Accepted Submission(s): 722 Pr
阅读全文
摘要:Queuing Time Limit: 10000/5000 MS (Java/Others) Memory Limit: 32768/32768 K (Java/Others)Total Submission(s): 6610 Accepted Submission(s): 2903 Proble
阅读全文
摘要:Problem of Precision Time Limit: 1000/1000 MS (Java/Others) Memory Limit: 32768/32768 K (Java/Others)Total Submission(s): 1695 Accepted Submission(s):
阅读全文
摘要:大吉大利今晚吃鸡 Problem Description 最近流行吃鸡,那就直接输出一行"Winner winner ,chicken dinner!"(没有双引号)模板代码:#include <stdio.h>int main(){printf("hello world\n");return 0;
阅读全文
摘要:Permutation 找规律 先输出奇数 1 2 3 4 5... 偶数就用剩下的依次加1 找规律 先输出奇数 1 2 3 4 5... 偶数就用剩下的依次加1 1 #include <bits/stdc++.h> 2 using namespace std; 3 4 int main() { 5
阅读全文
摘要:Problem Description Giving two strings and you should judge if they are matched.The first string contains lowercase letters and uppercase letters.The
阅读全文
摘要:Pocket Cube Problem Description The Pocket Cube, also known as the Mini Cube or the Ice Cube, is the 2 × 2 × 2 equivalence of a Rubik’s Cube.The cube
阅读全文
摘要:Problem Description Zeus 和 Prometheus 做了一个游戏,Prometheus 给 Zeus 一个集合,集合中包含了N个正整数,随后 Prometheus 将向 Zeus 发起M次询问,每次询问中包含一个正整数 S ,之后 Zeus 需要在集合当中找出一个正整数 K
阅读全文
摘要:Problem Description 有很多从磁盘读取数据的需求,包括顺序读取、随机读取。为了提高效率,需要人为安排磁盘读取。然而,在现实中,这种做法很复杂。我们考虑一个相对简单的场景。磁盘有许多轨道,每个轨道有许多扇区,用于存储数据。当我们想在特定扇区来读取数据时,磁头需要跳转到特定的轨道、具体
阅读全文
摘要:Ignatius and the Princess II Problem Description Now our hero finds the door to the BEelzebub feng5166. He opens the door and finds feng5166 is about
阅读全文
摘要:Ford-Fulkerson算法是通过深度优先搜索寻找增广路,并沿着它增广。 与之相对,Dinic算法总是寻找最短的增广路,并沿着它增广。因为最短增广路的长度在增广过程中始终不会变短,所以无需每次都通过宽度预先搜索来寻找最短增广路。 我们可以先进行一次宽度优先搜索,然后考虑由进距离顶点指向远距离顶点
阅读全文