Power of CryptographyDescriptionCurrent work in 
cryptography involves (among other things) large prime numbers and computing 
powers of numbers among t...
                            
                            
                                分类:
其他好文   时间:
2014-05-09 03:43:36   
                                阅读次数:
260
                             
                         
                    
                        
                            
                            
                                /*
* uva10879
* Date:2014/5/7
* State:AC
*/
#include 
#include 
using namespace std;
int main()
{
    //cout << "Hello world!" <>N;
...
                            
                            
                                分类:
其他好文   时间:
2014-05-09 00:30:58   
                                阅读次数:
287
                             
                         
                    
                        
                            
                            
                                本文档下载题目:http://uva.onlinejudge.org/index.php?option=com_onlinejudge&Itemid=8&page=show_problem&problem=361 
The 3n + 1 problemTime limit: 3.000 seconds...
                            
                            
                                分类:
其他好文   时间:
2014-05-08 18:01:26   
                                阅读次数:
427
                             
                         
                    
                        
                            
                            
                                题目链接:点击打开链接
题意:
给定一个字符串str 求字符串str的
循环节个数为 1-len 个的
最长子串长度
思路:套用kmp的性质
#include
#include
#include 
using namespace std;
#define n 1300
void getnext(char str[n],int next[n]){
	int m=strlen(str);...
                            
                            
                                分类:
其他好文   时间:
2014-05-08 17:12:53   
                                阅读次数:
330
                             
                         
                    
                        
                            
                            
                                这真是一个耗CPU的运算,怪不得现在因式分解和素数查找现在都用于加密运算。By listing the 
first six prime numbers: 2, 3, 5, 7, 11, and 13, we can see that the 6th prime 
is 13.What is the 1...
                            
                            
                                分类:
其他好文   时间:
2014-05-08 11:54:49   
                                阅读次数:
260
                             
                         
                    
                        
                            
                            
                                题目链接:uva 1543 - Telescope
题目大意:...
                            
                            
                                分类:
其他好文   时间:
2014-05-08 04:28:25   
                                阅读次数:
364
                             
                         
                    
                        
                            
                            
                                题目链接:点击打开链接
题意:
切水果游戏
给出n个水果
水果出现在屏幕上的时间的区间
1、每次切会把屏幕上所有水果切完
2、当同时切3个或以上时计分,分数为切的水果个数
3、不能遗漏水果
问最高得分
dp[i] 表示 最后一次切第i个的得分。
#include
#include
#include
#include
using namespace std;
#define N ...
                            
                            
                                分类:
其他好文   时间:
2014-05-07 23:36:52   
                                阅读次数:
346
                             
                         
                    
                        
                            
                            
                                题目链接:click here~
此题我估计是加强过数据,在我纠结了很久的时候我交了好几份网上的代码不是WA就是TLE。在我很迷茫的时候我又交了一份,AC了(虽然我用随机数据找到了他代码一个不能过的数据)。
给了我信心,然后我拿他的代码用随机数跟我的代码进行测试,再用FC找不同。。发现了一个致命的错误,一般来说,BFS或者DFS都是需要有一个vis数组或者哈希来判重,但是此题判重是有很大问题的...
                            
                            
                                分类:
其他好文   时间:
2014-05-07 22:48:42   
                                阅读次数:
400
                             
                         
                    
                        
                            
                            
                                题目链接:uva 11782 - Optimal Cut
题目大意:按照前序给出一棵完全树的qia...
                            
                            
                                分类:
其他好文   时间:
2014-05-07 16:34:29   
                                阅读次数:
312
                             
                         
                    
                        
                            
                            
                                题目如下:
The Dole Queue 
In a serious attempt to downsize (reduce) the dole queue, The NewNational Green Labour Rhinoceros Party has decided on the followingstrategy. Every day ...
                            
                            
                                分类:
其他好文   时间:
2014-05-07 15:46:40   
                                阅读次数:
235