上一页 1 2 3 4 5 6 7 ··· 10 下一页
摘要: 描述 给定整数 N(1≤N≤10^6),试把阶乘 N! 分解质因数,按照算术基本定理的形式输出分解结果中的 p_i 和 c_i 即可。 输入格式 一个整数N。 输出格式 N! 分解质因数后的结果,共若干行,每行一对pi, ci,表示含有pi^ci项。按照pi从小到大的顺序输出。 样例输入 样例输出 阅读全文
posted @ 2019-04-11 22:43 进击的黑仔 阅读(529) 评论(0) 推荐(0) 编辑
摘要: The branch of mathematics called number theory is about properties of numbers. One of the areas that has captured the interest of number theoreticians 阅读全文
posted @ 2019-04-11 22:36 进击的黑仔 阅读(234) 评论(0) 推荐(0) 编辑
摘要: 对于任何正整数x,其约数的个数记作g(x)。例如g(1)=1、g(6)=4。如果某个正整数x满足:g(x)>g(i) 0<i<x ,则称x为反质数。例如,整数1,2,4,6等都是反质数。现在给定一个数N,你能求出不超过N的最大的反质数么? Input 一个数N(1<=N<=2,000,000,000 阅读全文
posted @ 2019-04-11 22:31 进击的黑仔 阅读(228) 评论(0) 推荐(0) 编辑
摘要: 恢复内容开始 Kurt reaches nirvana when he finds the product of all the digits of some positive integer. Greater value of the product makes the nirvana deepe 阅读全文
posted @ 2019-04-11 00:36 进击的黑仔 阅读(132) 评论(0) 推荐(0) 编辑
摘要: 恢复内容开始 You are given a rooted tree with vertices numerated from 11 to nn . A tree is a connected graph without cycles. A rooted tree has a special ver 阅读全文
posted @ 2019-04-11 00:15 进击的黑仔 阅读(649) 评论(0) 推荐(0) 编辑
摘要: For their physical fitness program, N (2 ≤ N ≤ 1,000,000) cows have decided to run a relay race using the T (2 ≤ T ≤ 100) cow trails throughout the pa 阅读全文
posted @ 2019-04-10 00:26 进击的黑仔 阅读(189) 评论(0) 推荐(0) 编辑
摘要: Andy the smart computer science student was attending an algorithms class when the professor asked the students a simple question, "Can you propose an 阅读全文
posted @ 2019-04-09 13:52 进击的黑仔 阅读(278) 评论(0) 推荐(0) 编辑
摘要: Farmer John wants to set up a telephone line at his farm. Unfortunately, the phone company is uncooperative, so he needs to pay for some of the cables 阅读全文
posted @ 2019-04-09 13:29 进击的黑仔 阅读(165) 评论(0) 推荐(0) 编辑
摘要: 描述C国有 n 个大城市和 m 条道路,每条道路连接这 n 个城市中的某两个城市。任意两个城市之间最多只有一条道路直接相连。这 m 条道路中有一部分为单向通行的道路,一部分为双向通行的道路,双向通行的道路在统计条数时也计为1条。C国幅员辽阔,各地的资源分布情况各不相同,这就导致了同一种商品在不同城市 阅读全文
posted @ 2019-04-09 13:00 进击的黑仔 阅读(226) 评论(0) 推荐(0) 编辑
摘要: An ascending sorted sequence of distinct values is one in which some form of a less-than operator is used to order the elements from smallest to large 阅读全文
posted @ 2019-04-09 12:33 进击的黑仔 阅读(251) 评论(0) 推荐(0) 编辑
上一页 1 2 3 4 5 6 7 ··· 10 下一页