上一页 1 ··· 33 34 35 36 37 38 39 40 41 ··· 50 下一页
摘要: Longest Collatz sequence The following iterative sequence is defined for the set of positive integers: n → n/2 (n is even) n → 3n + 1 (n is odd) Using 阅读全文
posted @ 2020-02-18 20:28 quanjun 阅读(288) 评论(0) 推荐(0) 编辑
摘要: Large sum Work out the first ten digits of the sum of the following one hundred 50 digit numbers. 大和 计算出以下一百个50位数的和的前十位数字。 解题思路 目前想到的就是用高精度加法模拟。 100个5 阅读全文
posted @ 2020-02-18 19:20 quanjun 阅读(461) 评论(0) 推荐(0) 编辑
摘要: 题目链接: "https://www.luogu.com.cn/problem/P1016" 解题思路(思路全部来自 "hongzy大神的博客" ): 思路: 1. 在起点加满油; 2. 到第i个加油站把油箱里价格 P[i]的油退了,换成价格为P[i]的油。 3. 每次烧油就找最便宜的油烧 实现:单 阅读全文
posted @ 2020-02-18 12:04 quanjun 阅读(182) 评论(0) 推荐(0) 编辑
摘要: Highly divisible triangular number The sequence of triangle numbers is generated by adding the natural numbers. So the 7th triangle number would be 1 阅读全文
posted @ 2020-02-17 19:34 quanjun 阅读(324) 评论(0) 推荐(1) 编辑
摘要: Largest product in a grid In the 20×20 grid below, four numbers along a diagonal line have been marked in red. 08 02 22 97 38 15 00 40 00 75 04 05 07 阅读全文
posted @ 2020-02-17 18:49 quanjun 阅读(148) 评论(0) 推荐(0) 编辑
摘要: Summation of primes The sum of the primes below 10 is 2 + 3 + 5 + 7 = 17. Find the sum of all the primes below two million. 素数的和 所有小于10的素数的和是2 + 3 + 5 阅读全文
posted @ 2020-02-17 18:34 quanjun 阅读(172) 评论(0) 推荐(0) 编辑
摘要: Special Pythagorean triplet A Pythagorean triplet is a set of three natural numbers, $a using namespace std; int main() { for (int i = 1; i <= 1000/3; 阅读全文
posted @ 2020-02-17 18:25 quanjun 阅读(206) 评论(0) 推荐(0) 编辑
摘要: Largest product in a series The four adjacent digits in the 1000 digit number that have the greatest product are 9 × 9 × 8 × 9 = 5832. Find the thirte 阅读全文
posted @ 2020-02-17 18:14 quanjun 阅读(492) 评论(0) 推荐(0) 编辑
摘要: 10001st prime By listing the first six prime numbers: 2, 3, 5, 7, 11, and 13, we can see that the 6th prime is 13. What is the 10 001st prime number? 阅读全文
posted @ 2020-02-17 18:07 quanjun 阅读(201) 评论(0) 推荐(0) 编辑
摘要: Sum square difference The sum of the squares of the first ten natural numbers is, $$1^2 + 2^2 + \cdots + 10^2 = 385$$ The square of the sum of the fir 阅读全文
posted @ 2020-02-17 17:57 quanjun 阅读(180) 评论(0) 推荐(0) 编辑
上一页 1 ··· 33 34 35 36 37 38 39 40 41 ··· 50 下一页