链接:http://uva.onlinejudge.org/index.php?option=com_onlinejudge&Itemid=8&page=show_problem&problem=967描述:要做n双鞋子,第 i 双鞋子要做Ti天,每天消耗Si的钱(当前正在做第 i 双鞋子时不耗钱)...
分类:
其他好文 时间:
2014-07-14 08:26:03
阅读次数:
201
DAY1A UVAlive 3937 painting the sticks给你一些木棒,按照给定的颜色序列染色,每次最多可以染连续的3块(每块的颜色可以不一样),每块可以由任意多个连续木棒组成,求最少步数。题目里有说不允许覆盖染色吗?统计不同的颜色块的个数,除以3并向上取整就是答案了。。B UVa...
分类:
其他好文 时间:
2014-07-14 00:04:32
阅读次数:
249
uva11992:http://uva.onlinejudge.org/index.php?option=com_onlinejudge&Itemid=8&page=show_problem&problem=3143题意:给你n*m的矩阵初始化的时候矩阵里面的元素全部是0,对于这个矩阵有3中操作。1...
分类:
其他好文 时间:
2014-07-13 22:35:03
阅读次数:
286
uva12299:http://uva.onlinejudge.org/index.php?option=com_onlinejudge&Itemid=8&page=show_problem&problem=3720题意:给你n个数,然后有两个操做,shift从左到右一次交换,即a1和a2交换,完了...
分类:
其他好文 时间:
2014-07-13 21:32:18
阅读次数:
261
uva11525:http://uva.onlinejudge.org/index.php?option=com_onlinejudge&Itemid=8&page=show_problem&problem=2520题意:求1,2,3,4,.....k个数所形成的全排列中的第n个。其中n的是由计算出...
分类:
其他好文 时间:
2014-07-13 21:13:52
阅读次数:
261
题目链接:http://uva.onlinejudge.org/index.php?option=com_onlinejudge&Itemid=8&page=show_problem&problem=6913874119133The Dole QueueAcceptedC++0.0092014-07...
分类:
其他好文 时间:
2014-07-13 20:59:42
阅读次数:
226
题目连接:uva 10560 - Minimum Weight题目大意:给出n,问说至少须要多少个不同重量的砝码才干称量1~n德重量,给出所选的砝码重量,而且给出k,表示有k个重量须要用上述所选的砝码測量。解题思路:重量为1的砝码肯定要选,它能够表示到1的重量,那么下一个砝码的重量肯定选择3(2?1...
分类:
其他好文 时间:
2014-07-13 20:22:53
阅读次数:
192
Matrix Chain Multiplication
Suppose you have to evaluate an expression like A*B*C*D*E where A,B,C,D and E are matrices. Since matrix multiplication is associative, the order in which multi...
分类:
其他好文 时间:
2014-07-13 18:10:40
阅读次数:
223
Parentheses Balance
You are given a string consisting of parentheses () and []. A string of this type is said to be correct:
(a)if it is the empty string(b)if A and B are correct, AB is c...
分类:
其他好文 时间:
2014-07-13 15:42:59
阅读次数:
207