码迷,mamicode.com
首页 >  
搜索关键字:uva 11361    ( 8022个结果
UVa 1354 天平难题
首先呈现刘汝佳的高级代码 cpp // UVa1354 Mobile Computing // Rujia Liu include include include using namespace std; struct Tree { double L, R; // distance from the ...
分类:其他好文   时间:2018-08-22 22:52:27    阅读次数:344
UVa 10410 树重建
Tree Reconstruction Problem Description You have just finished a compiler design homework question where you had to find the parse tree of an expressi ...
分类:其他好文   时间:2018-08-22 22:49:00    阅读次数:193
UVA506-System Dependencies(拓扑序)
Problem UVA506-System Dependencies Accept:285 Submit:2824 Time Limit: 3000 mSec Problem Description Components of computer systems often have dependen ...
分类:其他好文   时间:2018-08-22 21:58:11    阅读次数:223
Uva1639(概率期望/对数处理避免丢失精度)
Uva1639 题意: 有两个盒子各有n个糖果(n<=200000),每天随机选择一个:选第一个盒子的概率是p(0 ≤ p ≤ 1),第二个盒子的概率为1-p,然后吃掉其中的一颗。直到有一天,随机选择一个盒子打开一看,没糖了!现在请你计算另一个盒子里剩下的糖果数量的期望值。 解法: 我们假设到第n天 ...
分类:其他好文   时间:2018-08-22 00:12:53    阅读次数:180
2018.8.18练习赛
HDU 2089 不要62 数据量比较小,还是直接暴力吧。 HDU 1207 汉诺塔II 汉诺塔的变型,增加了一根柱子,直接上队里大神写的代码。 HDU 2680 Choose the best route 多个起点,一个终点,反向存图,跑一遍Dijkstra,比较得出最短路即可。 UVa Anan ...
分类:其他好文   时间:2018-08-20 19:00:14    阅读次数:164
UVa 156 <map>启蒙
map函数的启蒙篇,如何实现字符串对于数值的映射达到查重效果(map中同一个元素只能存在一次)。 map函数提供了find()以及count()。 include include include include include using namespace std; vector word; ma ...
分类:其他好文   时间:2018-08-19 22:04:31    阅读次数:204
UVa 11995 猜猜数据结构
代码来自蓝书第三章第一题,思路很清晰。主要实现过程中需要区分以下数据结构: stack queue priority_queue include include include include using namespace std; const int maxn = 1000 + 10; int ...
分类:其他好文   时间:2018-08-19 21:57:40    阅读次数:150
Recurrences UVA - 10870 (斐波拉契的一般形式推广)
题意:f(n) = a1f(n?1) + a2f(n?2) + a3f(n?3) + ... + adf(n?d), 计算这个f(n) 最重要的是推出矩阵。 ...
分类:其他好文   时间:2018-08-19 17:32:44    阅读次数:153
Uva10820 欧拉公式模板(求小于n且与n互素的数的个数)
题意: 给出n,算出小于等于n的所有数中,有几对互质; 解法: 本质就是求有多少个2元组(x,y)满足:1 <= x,y <= n,且x与y互素。 除了(1,1)之外,其他所有的x和y都不相同,我们设x<y的二元组有f(n)个,答案就是2f(n)+1 f(n)=phi(2)+phi(3)+...+p ...
分类:其他好文   时间:2018-08-19 11:06:07    阅读次数:189
UVA 11729
UVA 11729 大体是贪心做法,执行时间长的先交代 训练指南原题解 include include include using namespace std; struct Job { int j, b; bool operator x.j; } }; int main() { int n, b, ...
分类:其他好文   时间:2018-08-18 10:31:54    阅读次数:161
8022条   上一页 1 ... 57 58 59 60 61 ... 803 下一页
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!