freeCodeCamp/curriculum/challenges/english/10-coding-interview-prep/project-euler/problem-118-pandigital-prime-sets.english.md
mrugesh 22afc2a0ca feat(learn): python certification projects (#38216)
Co-authored-by: Oliver Eyton-Williams <ojeytonwilliams@gmail.com>
Co-authored-by: Kristofer Koishigawa <scissorsneedfoodtoo@gmail.com>
Co-authored-by: Beau Carnes <beaucarnes@gmail.com>
2020-05-27 13:19:08 +05:30

994 B

id, challengeType, isHidden, title, forumTopicId
id challengeType isHidden title forumTopicId
5900f3e21000cf542c50fef5 5 false Problem 118: Pandigital prime sets 301744

Description

Using all of the digits 1 through 9 and concatenating them freely to form decimal integers, different sets can be formed. Interestingly with the set {2,5,47,89,631}, all of the elements belonging to it are prime. How many distinct sets containing each of the digits one through nine exactly once contain only prime elements?

Instructions

Tests

tests:
  - text: <code>euler118()</code> should return 44680.
    testString: assert.strictEqual(euler118(), 44680);

Challenge Seed

function euler118() {
  // Good luck!
  return true;
}

euler118();

Solution

// solution required