Back to Freecodecamp

Problem 146: Investigating a Prime Pattern

curriculum/challenges/english/blocks/project-euler-problems-101-to-200/5900f3fe1000cf542c50ff11.md

latest570 B
Original Source

--description--

The smallest positive integer $n$ for which the numbers $n^2 + 1$, $n^2 + 3$, $n^2 + 7$, $n^2 + 9$, $n^2 + 13$, and $n^2 + 27$ are consecutive primes is 10. The sum of all such integers $n$ below one-million is 1242490.

What is the sum of all such integers $n$ below 150 million?

--hints--

primePattern() should return 676333270.

js
assert.strictEqual(primePattern(), 676333270);

--seed--

--seed-contents--

js
function primePattern() {

  return true;
}

primePattern();

--solutions--

js
// solution required