》题意:给一个函数的定义,F(n)代表n的所有约数之和,并且给出了整数拆分公式以及F(n)的计算方法,对于一个给出的N让我们求1 - N之间有多少个数满足F(x)为偶数的情况,输出这个数。 》分析:来考虑F(x)为奇数的情况,给据题目中给我们的公式,,如果F(x)为奇数,那么这个多项式里面的任何一项 ...
分类:
其他好文 时间:
2016-06-17 16:56:30
阅读次数:
170
You work in a company which organizes marriages. Marriages are not that easy to be made, so, the job is quite hard for you. The job gets more difficul ...
分类:
其他好文 时间:
2016-06-15 08:01:53
阅读次数:
320
题意:题目给出一个欧拉函数值F(X),让我们求>=这个函数值的最小数N,使得F(N) >= F(X); 分析:这个题目有两种做法。第一种,暴力打出欧拉函数表,然后将它调整成有序的,再建立一个新的表格记录满足条件的最小的欧拉值。 第二种,根据欧拉函数的性质,针对一个素数N,F(N) = N-1; 然后 ...
分类:
其他好文 时间:
2016-06-14 13:56:56
阅读次数:
120
题目链接:http://lightoj.com/volume_showproblem.php?problem=1017 题意:给你一个无限大的平面(2D)上面有N个 点,一个宽w的刷子,最多使用k次,每次使用只能横着水平刷一次。问刷k次后刷过的地方最多可以覆盖多少个点。 思路:其实读完题就知道这个题 ...
分类:
其他好文 时间:
2016-06-13 01:19:08
阅读次数:
168
题目链接:http://lightoj.com/login_main.php?url=volume_showproblem.php?problem=1004 题意:数塔的变形,上面一个下面一个,看清楚了直接做就行了。 上半部分转移方程dp(i,j)=max(dp(i-1,j),dp(i-1,j+1) ...
分类:
其他好文 时间:
2016-06-13 01:05:39
阅读次数:
155
1007 - Mathematically Hard PDF (English) Statistics Forum Time Limit: 2 second(s) Memory Limit: 64 MB Mathematically some problems look hard. But with ...
分类:
其他好文 时间:
2016-06-10 20:17:33
阅读次数:
201
看了kuangbin神的版子,自己的都不敢往上贴了。。。 #include <cstdio>#include <cstring>#include <algorithm>#include <cstdlib>#include <iostream>#include <vector>#include <cm ...
分类:
其他好文 时间:
2016-06-10 13:43:27
阅读次数:
162
Given a code (not optimized), and necessary inputs, you have to find the output of the code for the inputs. The code is as follows: int a, b, c, d, e, ...
分类:
其他好文 时间:
2016-06-10 12:21:41
阅读次数:
202