Files
freeCodeCamp/curriculum/challenges/english/10-coding-interview-prep/project-euler/problem-108-diophantine-reciprocals-i.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

1.0 KiB

id, challengeType, isHidden, title, forumTopicId
id challengeType isHidden title forumTopicId
5900f3d91000cf542c50feeb 5 false Problem 108: Diophantine Reciprocals I 301732

Description

In the following equation x, y, and n are positive integers. 1/x + 1/y = 1/n For n = 4 there are exactly three distinct solutions: 1/5 + 1/20 = 1/4
1/6 + 1/12 = 1/4
1/8 + 1/8 = 1/4 What is the least value of n for which the number of distinct solutions exceeds one-thousand?

Instructions

Tests

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

Challenge Seed

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

diophantineOne();

Solution

// solution required