freeCodeCamp/curriculum/challenges/english/10-coding-interview-prep/project-euler/problem-303-multiples-with-small-digits.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

894 B

id, challengeType, isHidden, title, forumTopicId
id challengeType isHidden title forumTopicId
5900f49b1000cf542c50ffae 5 false Problem 303: Multiples with small digits 301957

Description

For a positive integer n, define f(n) as the least positive multiple of n that, written in base 10, uses only digits ≤ 2. Thus f(2)=2, f(3)=12, f(7)=21, f(42)=210, f(89)=1121222. Also, .

Find .

Instructions

Tests

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

Challenge Seed

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

euler303();

Solution

// solution required