Stack Exchange Network

Stack Exchange network consists of 175 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.

Visit Stack Exchange
    Notice removed Reward existing answer by Addison Crump
    Bounty Ended with Dennis's answer chosen by Addison Crump
10 edited tags
| link
    Notice added Reward existing answer by Addison Crump
    Bounty Started worth 500 reputation by Addison Crump
    Notice removed Draw attention by user48538
    Bounty Ended with Dennis's answer chosen by user48538
    Notice added Draw attention by user48538
    Bounty Started worth 50 reputation by user48538
9 added 54 characters in body
source | link
  • Your code should work for n up to 2 billion ( 2,000,000,000 ).

  • Built-ins that trivialize this are not allowed. This includes built in π functions or lists of values for π(n).

  • Built-ins that test primality or generate primes are not allowed. This includes lists of primes, which may not be looked up externally or hardcoded locally, except with regards to the next bullet point.

  • You may hardcode primes up to and including 19 and no higher.

  • your implementation of π should be deterministic. This means that given a specific n, your code should run in (approximately) the same amount of time.

  • Languages used must be freely available on Linux (Centos 7). Instructions should be included on how to run your code. Include compiler/interpreter details if necessary.

  • Official times will be from my computer.

  • When posting, please include a self-measured time on some/all of the test/score cases, just to give me an estimate of how fast your code is running.

  • Submissions must fit in an answer post to this question.

  • I am running 64bit centos7. I only have 8GB of RAM and 1GB swap. The cpu model is: AMD FX(tm)-6300 Six-Core Processor.

  • Your code should work for n up to 2 billion ( 2,000,000,000 ).

  • Built-ins that trivialize this are not allowed. This includes built in π functions or lists of values for π(n).

  • Built-ins that test primality or generate primes are not allowed. This includes lists of primes, which may not be looked up externally or hardcoded locally, except with regards to the next bullet point.

  • You may hardcode primes up to and including 19 and no higher.

  • your implementation of π should be deterministic. This means that given a specific n, your code should run in (approximately) the same amount of time.

  • Languages used must be freely available on Linux (Centos 7). Instructions should be included on how to run your code. Include compiler/interpreter details if necessary.

  • Official times will be from my computer.

  • When posting, please include a self-measured time on some/all of the test/score cases, just to give me an estimate of how fast your code is running.

  • Submissions must fit in an answer post to this question.

  • I am running 64bit centos7. I only have 8GB of RAM and 1GB swap.

  • Your code should work for n up to 2 billion ( 2,000,000,000 ).

  • Built-ins that trivialize this are not allowed. This includes built in π functions or lists of values for π(n).

  • Built-ins that test primality or generate primes are not allowed. This includes lists of primes, which may not be looked up externally or hardcoded locally, except with regards to the next bullet point.

  • You may hardcode primes up to and including 19 and no higher.

  • your implementation of π should be deterministic. This means that given a specific n, your code should run in (approximately) the same amount of time.

  • Languages used must be freely available on Linux (Centos 7). Instructions should be included on how to run your code. Include compiler/interpreter details if necessary.

  • Official times will be from my computer.

  • When posting, please include a self-measured time on some/all of the test/score cases, just to give me an estimate of how fast your code is running.

  • Submissions must fit in an answer post to this question.

  • I am running 64bit centos7. I only have 8GB of RAM and 1GB swap. The cpu model is: AMD FX(tm)-6300 Six-Core Processor.

8 added 98 characters in body
source | link

Also, the official times have been appended to each entry. Please double check your own average.

Also, the official times have been appended to each entry. Please double check your own average.

7 added 1412 characters in body
source | link
6 added 41 characters in body
source | link
5 added 29 characters in body
source | link
    Tweeted twitter.com/StackCodeGolf/status/703321111627485184
4 tags shouldn't go in titles and titles not in challenge bodies. also made the title a bit more expressive.
source | link
3 added 107 characters in body
source | link
2 added 30 characters in body
source | link
1
source | link