摘要: RomanticTime Limit: 2000/1000 MS (Java/Others)Memory Limit: 32768/32768 K (Java/Others)Total Submission(s): 2385Accepted Submission(s): 944Problem DescriptionThe Sky is Sprite.The Birds is Fly in the Sky.The Wind is Wonderful.Blew Throw the TreesTrees are Shaking, Leaves are Falling.Lovers Walk pass 阅读全文
posted @ 2013-08-11 19:20 芷水 阅读(368) 评论(0) 推荐(0) 编辑
摘要: 阶乘因式分解(一)时间限制:3000ms | 内存限制:65535KB难度:2描述给定两个数m,n,其中m是一个素数。将n(0 2 3 int Euler(int n,int m) 4 { 5 int k=0; 6 while(n) 7 { 8 n=n/m; 9 k=k+n;10 }11 return k;12 }13 14 int main()15 {16 int T,n,m;17 while(scanf("%d",&T)>0)18 {19 while(T--)20 ... 阅读全文
posted @ 2013-08-11 16:15 芷水 阅读(205) 评论(0) 推荐(0) 编辑
摘要: 因子和阶乘时间限制:1000ms | 内存限制:65535KB难度:2http://acm.nyist.net/JudgeOnline/problem.php?pid=509描述给你一个正整数n,把n!=1x2x3x.....xn分解成素因子相乘的形式,并从小到大输出每个素因子的指数,但要保证最后输出的素因子个数不为0。例如825应表示为0,1,2,0,1表示分别有0,1,2,0,1个2,3,5,7,11。输入第一行有一个整数n(0N/p1^1+(N/p1^1)/p1^1+((N/p1^1)/p1^1)/p1^1;这样的话就可以写成一个solve函数。 1 #include 2 #includ 阅读全文
posted @ 2013-08-11 09:43 芷水 阅读(227) 评论(0) 推荐(0) 编辑
摘要: Problem 1075 分解素因子Accept: 1331Submit: 2523Time Limit: 1000 mSecMemory Limit : 32768 KB Problem Description假设x是一个正整数,它的值不超过65535(即1 7 #include 8 9 void Euler(int n)10 {11 int i,k=0;12 for(i=2;i*i0)39 {40 while(n--)41 {42 scanf("%d",&m);43 Euler(m);... 阅读全文
posted @ 2013-08-11 08:54 芷水 阅读(193) 评论(0) 推荐(0) 编辑