码迷,mamicode.com
首页 >  
搜索关键字:找规律    ( 1218个结果
zoj 3629 Treasure Hunt IV 打表找规律
H - Treasure Hunt IV Time Limit:2000MS Memory Limit:65536KB 64bit IO Format:%lld & %lluDescription Alice is exploring the wonderland, suddenly she f.....
分类:其他好文   时间:2015-03-07 15:22:29    阅读次数:125
URAL 1295. Crazy Notions(数学啊 & 找规律)
URAL 1295. Crazy Notions(数学啊 & 找规律)...
分类:其他好文   时间:2015-03-07 11:38:06    阅读次数:124
观察表达式的规律,计算前n项的和
观察下列表达式的规律,计算前n项的和 2/1 + 3/2 +5/3 +8/5 +13/8+ 21/13 思路:不能有斐波那契额数推分母分子分别为前两项分母分子的和,因为n == 100时,斐波那契数会很大,超出范围,所以找规律:F(n) = 1/F(n-1)+1; #include #include #include #include #include #include #inc...
分类:其他好文   时间:2015-03-06 12:46:00    阅读次数:126
hdu 2516 取石子游戏
题目链接:http://acm.hdu.edu.cn/showproblem.php?pid=2516题意分析:乍一看是巴什博弈,后来发现博弈只是个噱头,关键还是找规律。/*取石子游戏Time Limit: 2000/1000 MS (Java/Others) Memory Limit: 32...
分类:其他好文   时间:2015-03-06 09:54:16    阅读次数:175
ZOJ 3622 Magic Number 打表找规律
A - Magic Number Time Limit:2000MS Memory Limit:32768KB 64bit IO Format:%lld & %lluSubmit Status Practice ZOJ 3622Appoint description:DescriptionA pos...
分类:其他好文   时间:2015-03-05 22:04:09    阅读次数:184
SPOJ Problem 1030:Triple Fat Ladies
水题。。寻找第k个立方末三位为888的数。暴力找规律后O(1)解决,要开long long。#includeint n,i,j;long long s;int main(){ scanf("%d",&n); while(n--){ scanf("%lld",&s); ...
分类:其他好文   时间:2015-03-05 20:53:51    阅读次数:171
SPOJ Problem 3442:The last digit
求某数的某次幂最后一位,暴力找规律后取模。#include#includeint t,x,y,s;int a[20];int main(){ scanf("%d",&t); while(t--){ scanf("%d%d",&x,&y); s=2;x%=10;...
分类:其他好文   时间:2015-03-04 22:30:22    阅读次数:123
hdu1021(C++)
打表找规律,发现是n%4==2就是yes,否则是no#includeusing namespace std;int main(){int n;while (cin >> n){if (n % 4 == 2)cout << "yes" << endl;elsecout << "no" << endl;...
分类:编程语言   时间:2015-03-01 16:56:13    阅读次数:154
hdu1061(C++)
简单的找规律,不妨设N=10*x+a(a=N%10),那么N^N=(10*x+a)^N,用二项式展开定理可以知道N^N%10=a^N%10;由于0using namespace std; int main(){ int n, a, T;cin >> T; int p[4]; while (T--) ...
分类:编程语言   时间:2015-03-01 16:51:22    阅读次数:208
递推总结
这是摘选自网络的一段话,感觉不错,特此分享首先,确认:是否能easy的得到简单情况的解?然后,如果:规模为N-1的情况已经得到解决。最后,重点分析:当规模扩大到N时,怎样枚举出全部的情况,而且要确保对于每一种子情况都能用已经得到的数据解决。假设这样递推公式找不出来,能够尝试列出前几项,找规律。注意:...
分类:其他好文   时间:2015-03-01 11:41:49    阅读次数:123
1218条   上一页 1 ... 95 96 97 98 99 ... 122 下一页
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!