The third Zhou of Software engineering (i.)

Source: Internet
Author: User

Question 1: What are the criteria for this program?

I think the program is looking for a number ranging from 1 to 2^63-1, and then find out that a number cannot be divisible by the two contiguous numbers in the array RG "" and that only two consecutive numbers can be divisible, and the remaining number can be divisible.

Question 2: Does such a number exist? What is the minimum number that meets this condition?

It seems to be 1+2+2^2+2^3+......+2^ ((63-1)/2) = (2^32) -1/(2-1) = 2147483647, it feels wrong, but it's not very good.

Question 3: How long do you expect to be able to output the first result when running this program on a computer? The time is accurate to minutes (computer: Single core CPU 4.0G Hz, memory and hard disk resources are sufficient).

I passed Baidu and asked classmates, it is said to be a long time.

Question 4: How can I improve the efficiency of this program on multi-core computers?

Integrating two or more complete compute engine (kernel) multi-core computers in one processor can perform several operations at the same time, greatly improving execution speed.

The third Zhou of Software engineering (i.)

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.