Files
freeCodeCamp/curriculum/challenges/english/08-coding-interview-prep/project-euler/problem-251-cardano-triplets.english.md
Oliver Eyton-Williams f1c9b08cf3 fix(curriculum): add isHidden: false to challenges
This includes certificates (where it does nothing), but does not
include any translations.
2020-05-25 16:25:19 +05:30

947 B

id, challengeType, isHidden, title, forumTopicId
id challengeType isHidden title forumTopicId
5900f4671000cf542c50ff7a 5 false Problem 251: Cardano Triplets 301899

Description

A triplet of positive integers (a,b,c) is called a Cardano Triplet if it satisfies the condition:

For example, (2,1,5) is a Cardano Triplet.

There exist 149 Cardano Triplets for which a+b+c ≤ 1000.

Find how many Cardano Triplets exist such that a+b+c ≤ 110,000,000.

Instructions

Tests

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

Challenge Seed

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

euler251();

Solution

// solution required