随笔分类 -  数学题

SPOJ CPCRC1C Sum of Digits
摘要:题目连接 题意:计算从a到b每个数每位数字相加的和 code: #include <iostream> #include <cstdio> #include <cstdlib> #include <cstring> using namespace std; typedef unsigned long 阅读全文

posted @ 2016-07-22 20:59 Tob's_the_top 阅读(213) 评论(0) 推荐(0)

hdu 1425 sort
摘要:hdu 1425 sort 由于数的范围是限定的,考虑用哈希。 注意:此题不能用cin cout,会超时 阅读全文

posted @ 2016-04-28 15:24 Tob's_the_top 阅读(100) 评论(0) 推荐(0)

hdu1418 欧拉公式
摘要:hdu1418抱歉 欧拉公式: F(面数)+V(顶点数)-E(楞数)=2 #include <iostream> using namespace std; int main() { long long n,m; while(cin >> n >> m){ if(n == 0&& m == 0) br 阅读全文

posted @ 2016-04-28 12:13 Tob's_the_top 阅读(155) 评论(0) 推荐(0)

hdu1215七夕节 筛选法求公因子和
摘要:hdu1215七夕节 数据量比较大,筛选法求公因子和即可。 阅读全文

posted @ 2016-04-28 01:51 Tob's_the_top 阅读(210) 评论(0) 推荐(0)

hdu1215 The area
摘要:hdu 1215 The area 算抛物线和直线解析式,简单积分 阅读全文

posted @ 2016-04-28 01:27 Tob's_the_top 阅读(145) 评论(0) 推荐(0)

hdu1005Number Sequence
摘要:思路:对于公式 f[n] = A * f[n-1] + B * f[n-2]; 后者只有7 * 7 = 49 种可能,为什么这么说,因为对于f[n-1] 或者 f[n-2] 的取值只有 0,1,2,3,4,5,6 这7个数,A,B又是固定的,所以就只有49种可能值了。由该关系式得知每一项只与前两项发 阅读全文

posted @ 2016-04-27 23:15 Tob's_the_top 阅读(150) 评论(0) 推荐(0)

hdu1021 数学题 并不是说难,而是数学题那种简单朴素的思想get不到
摘要:hdu1021 Fibonacci Again 一个斐波那契数列,求f[n]能否被3 整除。 注:虽然只是15ms 与 0 ms的区别!!!!!!! 阅读全文

posted @ 2016-04-27 11:20 Tob's_the_top 阅读(110) 评论(0) 推荐(0)

导航