- 博客(24)
- 资源 (1)
- 收藏
- 关注
原创 UVA 10405 - Longest Common Subsequence
Longest Common SubsequenceSequence 1: Sequence 2: Given two sequences of characters, print the length of the longest common subsequence of both sequences. For
2013-07-30 16:13:59 1011
原创 UVA 102 - Ecological Bin Packing(动态规划)
Ecological Bin Packing BackgroundBin packing, or the placement of objects of certain weights into different bins subject to certain constraints, is an historically interesting problem.
2013-07-30 15:35:57 3159
原创 UVA 111 - History Grading(动态规划)
History Grading BackgroundMany problems in Computer Science involve maximizing some measure according to constraints.Consider a history exam in which students are asked to put severa
2013-07-30 14:14:20 2081
原创 NYOJ 16 矩形嵌套(动态规划)
矩形嵌套时间限制:3000 ms | 内存限制:65535 KB难度:4描述有n个矩形,每个矩形可以用a,b来描述,表示长和宽。矩形X(a,b)可以嵌套在矩形Y(c,d)中当且仅当a<c,b<d或者b<c,a<d(相当于旋转X90度)。例如(1,5)可以嵌套在(6,2)内,但不能嵌套在(3,4)中。你的任务是选出尽可能多的矩形排成一行,使得除最后一个外,每一个矩
2013-07-29 16:32:05 1643
原创 NYOJ 496 巡回赛 拓扑排序
巡回赛时间限制:1000 ms | 内存限制:65535 KB难度:3描述世界拳击协会(WBA)是历史最悠久的世界性拳击组织,孕育了众多的世界冠军,尤其是重量级,几乎造就了大家耳熟能详的所有伟大的拳王。阿里、弗雷泽、福尔曼被称为“70年代重量级拳坛 三巨头”,是当之无愧的拳王,他们的得到的金腰带都刻有 WBA 字样。为庆贺世界拳击协会成
2013-07-29 11:39:55 1478
原创 UVA 507 - Jill Rides Again 动态规划
Jill Rides Again Jill likes to ride her bicycle, but since the pretty city of Greenhills where she lives has grown, Jill often uses the excellent public bus system for part of her journey.
2013-07-25 15:23:57 1612 1
原创 UVA 10487 - Closest Sums
Closest SumsInput: standard inputOutput: standard outputTime Limit: 3 seconds Given is a set of integers and then a sequence of queries. A query gives you a number and asks to find a sum of
2013-07-24 14:30:50 1272
原创 UVA 10394 Twin Primes
Twin PrimesInput: standard inputOutput: standard outputTime Limit: 30 seconds Twin primes are pairs of primes of the form (p, p+2). The term "twin prime" was coined by Paul Stäckel (1892-191
2013-07-22 09:00:45 1429
原创 hdu 1010 Tempter of the Bone 深搜+剪枝
Problem DescriptionThe doggie found a bone in an ancient maze, which fascinated him a lot. However, when he picked it up, the maze began to shake, and the doggie could feel the ground sinking. He realized that the bone was a trap, and he tried desperately
2013-07-18 15:54:17 1055
原创 UVA 657 - The die is cast 深度搜索
657 - The die is castInterGames is a high-tech startup company that specializes in developing technology that allows users to play games over the Internet. A market analysis has alerted them to th
2013-07-17 18:42:03 2354 3
原创 UVA 216 - Getting in Line
216 - Getting in LineComputer networking requires that the computers in the network be linked.This problem considers a ``linear" network in which the computers are chained together so that eac
2013-07-17 09:38:15 1581
原创 UVA 146 - ID Codes 枚举排列
ID CodesIt is 2084 and the year of Big Brother has finally arrived, albeit a century late. In order to exercise greater control over its citizens and thereby to counter a chronic breakdown in law an
2013-07-16 17:55:39 2183
原创 暴力求解法 之 枚举排列
1、生成1~n的排列#include#includeconst int N=1e3+10;int a[N];void print_permutation(int n,int *a,int cur){ int i,j; if(cur==n) /*递归边界*/ { for(i=0;i<n;i++) printf("%d ",a
2013-07-15 16:02:04 3755
原创 暴力求解法 之 简单枚举
1、除法 输入正整数n,按从小到大的顺序输出所有形如abcde / fghij = n的表达式,其中a~j恰好为0~9的一个排列,2 样例输入:62 样例输出: 79546 / 01283 =62 94736 / 01528 =62分析: 枚举0~9的所有排列?没这个必要。只需要枚举fghij就可以算出abcde,然
2013-07-15 13:10:29 6572 6
原创 Codeforce 144B-Meeting 数学题
B. Meetingtime limit per test2 secondsmemory limit per test256 megabytesinputstandard inputoutputstandard outputThe Super Duper Secret Meeting of the Super Dupe
2013-07-13 17:27:30 1346
原创 Codeforce 143B - Help Kingdom of Far Far Away 2
B. Help Kingdom of Far Far Away 2time limit per test2 secondsmemory limit per test256 megabytesinputstandard inputoutputstandard outputFor some time the program
2013-07-13 13:53:41 1394
原创 hdu 1861-游船出租
游船出租 Time Limit: 1000/1000 MS (Java/Others) Memory Limit: 32768/32768 K (Java/Others)Problem Description
2013-07-13 10:57:33 2624
原创 UVA 568 - Just the Facts(数论)
Just the FactsThe expression N!, read as ``N factorial," denotes the product of the first N positive integers, where N is nonnegative. So, for example,NN!0111
2013-07-12 10:23:43 2965 1
原创 UVA 489 - Hangman Judge
Hangman JudgeIn ``Hangman Judge,'' you are to write a program that judges a series of Hangman games. For each game, the answer to the puzzle is given as well as the guesses. Rules are the same as
2013-07-11 15:56:16 3383
原创 UVA 445 - Marvelous Mazes
Marvelous MazesYour mission, if you decide to accept it, is to create a maze drawing program. A maze will consist of the alphabetic characters A-Z, * (asterisk), and spaces.Input and OutputY
2013-07-11 12:58:29 2581
原创 UVA 490 Rotating Sentences
Rotating SentencesIn ``Rotating Sentences,'' you are asked to rotate a series of input sentences 90 degrees clockwise. So instead of displaying the input sentences from left to right and top t
2013-07-11 11:28:02 2373
原创 hdu 1062 Text Reverse 字符串
Text Reverse Time Limit: 2000/1000 MS (Java/Others) Memory Limit: 65536/32768 K (Java/Others)Problem Desc
2013-07-09 17:31:33 9384 3
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人