fix(curriculum): Remove unnecessary assert message argument from English Coding Interview Prep challenges - Project Euler - 04 (#36418)

* fix: removed assert msg argument-4

* fix: remove double quotes surrounding testString code

Co-Authored-By: Tom <20648924+moT01@users.noreply.github.com>
This commit is contained in:
Randell Dawson
2019-07-27 05:34:19 -07:00
committed by Tom
parent 5cf3b458fa
commit a7eb800450
74 changed files with 89 additions and 89 deletions

View File

@ -24,7 +24,7 @@ Find .
```yml ```yml
tests: tests:
- text: <code>euler303()</code> should return 1111981904675169. - text: <code>euler303()</code> should return 1111981904675169.
testString: assert.strictEqual(euler303(), 1111981904675169, '<code>euler303()</code> should return 1111981904675169.'); testString: assert.strictEqual(euler303(), 1111981904675169);
``` ```

View File

@ -35,7 +35,7 @@ Give your answer mod 1234567891011.
```yml ```yml
tests: tests:
- text: <code>euler304()</code> should return 283988410192. - text: <code>euler304()</code> should return 283988410192.
testString: assert.strictEqual(euler304(), 283988410192, '<code>euler304()</code> should return 283988410192.'); testString: assert.strictEqual(euler304(), 283988410192);
``` ```

View File

@ -31,7 +31,7 @@ Find ∑f(3k) for 1≤k≤13.
```yml ```yml
tests: tests:
- text: <code>euler305()</code> should return 18174995535140. - text: <code>euler305()</code> should return 18174995535140.
testString: assert.strictEqual(euler305(), 18174995535140, '<code>euler305()</code> should return 18174995535140.'); testString: assert.strictEqual(euler305(), 18174995535140);
``` ```

View File

@ -37,7 +37,7 @@ For 1 ≤ n ≤ 1 000 000, how many values of n are there for which the first pl
```yml ```yml
tests: tests:
- text: <code>euler306()</code> should return 852938. - text: <code>euler306()</code> should return 852938.
testString: assert.strictEqual(euler306(), 852938, '<code>euler306()</code> should return 852938.'); testString: assert.strictEqual(euler306(), 852938);
``` ```

View File

@ -27,7 +27,7 @@ Find p(20 000, 1 000 000) and give your answer rounded to 10 decimal places in t
```yml ```yml
tests: tests:
- text: <code>euler307()</code> should return 0.7311720251. - text: <code>euler307()</code> should return 0.7311720251.
testString: assert.strictEqual(euler307(), 0.7311720251, '<code>euler307()</code> should return 0.7311720251.'); testString: assert.strictEqual(euler307(), 0.7311720251);
``` ```

View File

@ -58,7 +58,7 @@ If someone uses the above Fractran program to solve Project Euler Problem 7 (fin
```yml ```yml
tests: tests:
- text: <code>euler308()</code> should return 1539669807660924. - text: <code>euler308()</code> should return 1539669807660924.
testString: assert.strictEqual(euler308(), 1539669807660924, '<code>euler308()</code> should return 1539669807660924.'); testString: assert.strictEqual(euler308(), 1539669807660924);
``` ```

View File

@ -30,7 +30,7 @@ For integer values x, y, h and 0 < x < y < 1 000 000, how many triplets (x,y,h)
```yml ```yml
tests: tests:
- text: <code>euler309()</code> should return 210139. - text: <code>euler309()</code> should return 210139.
testString: assert.strictEqual(euler309(), 210139, '<code>euler309()</code> should return 210139.'); testString: assert.strictEqual(euler309(), 210139);
``` ```

View File

@ -24,13 +24,13 @@ How many different ways can £(n) be made using any number of coins?
```yml ```yml
tests: tests:
- text: <code>coinSums(50)</code> should return 451. - text: <code>coinSums(50)</code> should return 451.
testString: assert(coinSums(50) == 451, '<code>coinSums(50)</code> should return 451.'); testString: assert(coinSums(50) == 451);
- text: <code>coinSums(100)</code> should return 4563. - text: <code>coinSums(100)</code> should return 4563.
testString: assert(coinSums(100) == 4563, '<code>coinSums(100)</code> should return 4563.'); testString: assert(coinSums(100) == 4563);
- text: <code>coinSums(150)</code> should return 21873. - text: <code>coinSums(150)</code> should return 21873.
testString: assert(coinSums(150) == 21873, '<code>coinSums(150)</code> should return 21873.'); testString: assert(coinSums(150) == 21873);
- text: <code>coinSums(200)</code> should return 73682. - text: <code>coinSums(200)</code> should return 73682.
testString: assert(coinSums(200) == 73682, '<code>coinSums(200)</code> should return 73682.'); testString: assert(coinSums(200) == 73682);
``` ```

View File

@ -26,7 +26,7 @@ Find the number of losing positions for the next player if 0≤a≤b≤c≤100 0
```yml ```yml
tests: tests:
- text: <code>euler310()</code> should return 2586528661783. - text: <code>euler310()</code> should return 2586528661783.
testString: assert.strictEqual(euler310(), 2586528661783, '<code>euler310()</code> should return 2586528661783.'); testString: assert.strictEqual(euler310(), 2586528661783);
``` ```

View File

@ -34,7 +34,7 @@ Find B(10 000 000 000).
```yml ```yml
tests: tests:
- text: <code>euler311()</code> should return 2466018557. - text: <code>euler311()</code> should return 2466018557.
testString: assert.strictEqual(euler311(), 2466018557, '<code>euler311()</code> should return 2466018557.'); testString: assert.strictEqual(euler311(), 2466018557);
``` ```

View File

@ -38,7 +38,7 @@ Find C(C(C(10 000))) mod 138.
```yml ```yml
tests: tests:
- text: <code>euler312()</code> should return 324681947. - text: <code>euler312()</code> should return 324681947.
testString: assert.strictEqual(euler312(), 324681947, '<code>euler312()</code> should return 324681947.'); testString: assert.strictEqual(euler312(), 324681947);
``` ```

View File

@ -30,7 +30,7 @@ How many grids does S(m,n) = p2, where p < 106 is prime?
```yml ```yml
tests: tests:
- text: <code>euler313()</code> should return 2057774861813004. - text: <code>euler313()</code> should return 2057774861813004.
testString: assert.strictEqual(euler313(), 2057774861813004, '<code>euler313()</code> should return 2057774861813004.'); testString: assert.strictEqual(euler313(), 2057774861813004);
``` ```

View File

@ -37,7 +37,7 @@ Give your answer rounded to 8 places behind the decimal point in the form abc.de
```yml ```yml
tests: tests:
- text: <code>euler314()</code> should return 132.52756426. - text: <code>euler314()</code> should return 132.52756426.
testString: assert.strictEqual(euler314(), 132.52756426, '<code>euler314()</code> should return 132.52756426.'); testString: assert.strictEqual(euler314(), 132.52756426);
``` ```

View File

@ -66,7 +66,7 @@ Find the difference between the total number of transitions needed by Sam's cloc
```yml ```yml
tests: tests:
- text: <code>euler315()</code> should return 13625242. - text: <code>euler315()</code> should return 13625242.
testString: assert.strictEqual(euler315(), 13625242, '<code>euler315()</code> should return 13625242.'); testString: assert.strictEqual(euler315(), 13625242);
``` ```

View File

@ -34,7 +34,7 @@ Note: represents the floor function.
```yml ```yml
tests: tests:
- text: <code>euler316()</code> should return 542934735751917760. - text: <code>euler316()</code> should return 542934735751917760.
testString: assert.strictEqual(euler316(), 542934735751917760, '<code>euler316()</code> should return 542934735751917760.'); testString: assert.strictEqual(euler316(), 542934735751917760);
``` ```

View File

@ -27,7 +27,7 @@ Give your answer rounded to four decimal places.
```yml ```yml
tests: tests:
- text: <code>euler317()</code> should return 1856532.8455. - text: <code>euler317()</code> should return 1856532.8455.
testString: assert.strictEqual(euler317(), 1856532.8455, '<code>euler317()</code> should return 1856532.8455.'); testString: assert.strictEqual(euler317(), 1856532.8455);
``` ```

View File

@ -46,7 +46,7 @@ Find ∑N(p,q) for p+q ≤ 2011.
```yml ```yml
tests: tests:
- text: <code>euler318()</code> should return 709313889. - text: <code>euler318()</code> should return 709313889.
testString: assert.strictEqual(euler318(), 709313889, '<code>euler318()</code> should return 709313889.'); testString: assert.strictEqual(euler318(), 709313889);
``` ```

View File

@ -35,7 +35,7 @@ Find t(1010) and give your answer modulo 109.
```yml ```yml
tests: tests:
- text: <code>euler319()</code> should return 268457129. - text: <code>euler319()</code> should return 268457129.
testString: assert.strictEqual(euler319(), 268457129, '<code>euler319()</code> should return 268457129.'); testString: assert.strictEqual(euler319(), 268457129);
``` ```

View File

@ -26,9 +26,9 @@ HINT: Some products can be obtained in more than one way so be sure to only incl
```yml ```yml
tests: tests:
- text: <code>pandigitalProducts()</code> is a function. - text: <code>pandigitalProducts()</code> is a function.
testString: assert(typeof pandigitalProducts === 'function', '<code>pandigitalProducts()</code> is a function.'); testString: assert(typeof pandigitalProducts === 'function');
- text: <code>pandigitalProducts()</code> should return 45228. - text: <code>pandigitalProducts()</code> should return 45228.
testString: assert.strictEqual(pandigitalProducts(), 45228, '<code>pandigitalProducts()</code> should return 45228.'); testString: assert.strictEqual(pandigitalProducts(), 45228);
``` ```

View File

@ -28,7 +28,7 @@ Find S(1 000 000) mod 1018.
```yml ```yml
tests: tests:
- text: <code>euler320()</code> should return 278157919195482660. - text: <code>euler320()</code> should return 278157919195482660.
testString: assert.strictEqual(euler320(), 278157919195482660, '<code>euler320()</code> should return 278157919195482660.'); testString: assert.strictEqual(euler320(), 278157919195482660);
``` ```

View File

@ -34,7 +34,7 @@ Find the sum of the first forty terms of this sequence.
```yml ```yml
tests: tests:
- text: <code>euler321()</code> should return 2470433131948040. - text: <code>euler321()</code> should return 2470433131948040.
testString: assert.strictEqual(euler321(), 2470433131948040, '<code>euler321()</code> should return 2470433131948040.'); testString: assert.strictEqual(euler321(), 2470433131948040);
``` ```

View File

@ -24,7 +24,7 @@ Find T(1018, 1012-10).
```yml ```yml
tests: tests:
- text: <code>euler322()</code> should return 999998760323314000. - text: <code>euler322()</code> should return 999998760323314000.
testString: assert.strictEqual(euler322(), 999998760323314000, '<code>euler322()</code> should return 999998760323314000.'); testString: assert.strictEqual(euler322(), 999998760323314000);
``` ```

View File

@ -27,7 +27,7 @@ Give your answer rounded to 10 digits after the decimal point.
```yml ```yml
tests: tests:
- text: <code>euler323()</code> should return 6.3551758451. - text: <code>euler323()</code> should return 6.3551758451.
testString: assert.strictEqual(euler323(), 6.3551758451, '<code>euler323()</code> should return 6.3551758451.'); testString: assert.strictEqual(euler323(), 6.3551758451);
``` ```

View File

@ -23,7 +23,7 @@ Find f(1010000) mod 100000007.
```yml ```yml
tests: tests:
- text: <code>euler324()</code> should return 96972774. - text: <code>euler324()</code> should return 96972774.
testString: assert.strictEqual(euler324(), 96972774, '<code>euler324()</code> should return 96972774.'); testString: assert.strictEqual(euler324(), 96972774);
``` ```

View File

@ -44,7 +44,7 @@ Find S(1016) mod 710.
```yml ```yml
tests: tests:
- text: <code>euler325()</code> should return 54672965. - text: <code>euler325()</code> should return 54672965.
testString: assert.strictEqual(euler325(), 54672965, '<code>euler325()</code> should return 54672965.'); testString: assert.strictEqual(euler325(), 54672965);
``` ```

View File

@ -33,7 +33,7 @@ Find f(1012,106).
```yml ```yml
tests: tests:
- text: <code>euler326()</code> should return 1966666166408794400. - text: <code>euler326()</code> should return 1966666166408794400.
testString: assert.strictEqual(euler326(), 1966666166408794400, '<code>euler326()</code> should return 1966666166408794400.'); testString: assert.strictEqual(euler326(), 1966666166408794400);
``` ```

View File

@ -41,7 +41,7 @@ Find ΣM(C,30) for 3 ≤ C ≤ 40.
```yml ```yml
tests: tests:
- text: <code>euler327()</code> should return 34315549139516. - text: <code>euler327()</code> should return 34315549139516.
testString: assert.strictEqual(euler327(), 34315549139516, '<code>euler327()</code> should return 34315549139516.'); testString: assert.strictEqual(euler327(), 34315549139516);
``` ```

View File

@ -42,7 +42,7 @@ Find C(n).
```yml ```yml
tests: tests:
- text: <code>euler328()</code> should return 260511850222. - text: <code>euler328()</code> should return 260511850222.
testString: assert.strictEqual(euler328(), 260511850222, '<code>euler328()</code> should return 260511850222.'); testString: assert.strictEqual(euler328(), 260511850222);
``` ```

View File

@ -31,7 +31,7 @@ Give your answer as a fraction p/q in reduced form.
```yml ```yml
tests: tests:
- text: <code>euler329()</code> should return 199740353 / 29386561536000. - text: <code>euler329()</code> should return 199740353 / 29386561536000.
testString: assert.strictEqual(euler329(), 199740353 / 29386561536000, '<code>euler329()</code> should return 199740353 / 29386561536000.'); testString: assert.strictEqual(euler329(), 199740353 / 29386561536000);
``` ```

View File

@ -23,7 +23,7 @@ If the product of these four fractions is given in its lowest common terms, find
```yml ```yml
tests: tests:
- text: <code>digitCancellingFractions()</code> should return 100. - text: <code>digitCancellingFractions()</code> should return 100.
testString: assert.strictEqual(digitCancellingFractions(), 100, '<code>digitCancellingFractions()</code> should return 100.'); testString: assert.strictEqual(digitCancellingFractions(), 100);
``` ```

View File

@ -39,7 +39,7 @@ Find A(109) + B(109) and give your answer mod 77 777 777.
```yml ```yml
tests: tests:
- text: <code>euler330()</code> should return 15955822. - text: <code>euler330()</code> should return 15955822.
testString: assert.strictEqual(euler330(), 15955822, '<code>euler330()</code> should return 15955822.'); testString: assert.strictEqual(euler330(), 15955822);
``` ```

View File

@ -37,7 +37,7 @@ Find .
```yml ```yml
tests: tests:
- text: <code>euler331()</code> should return 467178235146843500. - text: <code>euler331()</code> should return 467178235146843500.
testString: assert.strictEqual(euler331(), 467178235146843500, '<code>euler331()</code> should return 467178235146843500.'); testString: assert.strictEqual(euler331(), 467178235146843500);
``` ```

View File

@ -33,7 +33,7 @@ Find A(r). Give your answer rounded to six decimal places.
```yml ```yml
tests: tests:
- text: <code>euler332()</code> should return 2717.751525. - text: <code>euler332()</code> should return 2717.751525.
testString: assert.strictEqual(euler332(), 2717.751525, '<code>euler332()</code> should return 2717.751525.'); testString: assert.strictEqual(euler332(), 2717.751525);
``` ```

View File

@ -35,7 +35,7 @@ Find the sum of the primes q <1000000 such that P(q)=1.
```yml ```yml
tests: tests:
- text: <code>euler333()</code> should return 3053105. - text: <code>euler333()</code> should return 3053105.
testString: assert.strictEqual(euler333(), 3053105, '<code>euler333()</code> should return 3053105.'); testString: assert.strictEqual(euler333(), 3053105);
``` ```

View File

@ -43,7 +43,7 @@ Consider now 1500 adjacent bowls containing b1, b2,..., b1500 beans respectively
```yml ```yml
tests: tests:
- text: <code>euler334()</code> should return 150320021261690850. - text: <code>euler334()</code> should return 150320021261690850.
testString: assert.strictEqual(euler334(), 150320021261690850, '<code>euler334()</code> should return 150320021261690850.'); testString: assert.strictEqual(euler334(), 150320021261690850);
``` ```

View File

@ -28,7 +28,7 @@ Find M(2k+1). Give your answer modulo 79.
```yml ```yml
tests: tests:
- text: <code>euler335()</code> should return 5032316. - text: <code>euler335()</code> should return 5032316.
testString: assert.strictEqual(euler335(), 5032316, '<code>euler335()</code> should return 5032316.'); testString: assert.strictEqual(euler335(), 5032316);
``` ```

View File

@ -33,7 +33,7 @@ Find the 2011th lexicographic maximix arrangement for eleven carriages.
```yml ```yml
tests: tests:
- text: <code>euler336()</code> should return CAGBIHEFJDK. - text: <code>euler336()</code> should return CAGBIHEFJDK.
testString: assert.strictEqual(euler336(), CAGBIHEFJDK, '<code>euler336()</code> should return CAGBIHEFJDK.'); testString: assert.strictEqual(euler336(), CAGBIHEFJDK);
``` ```

View File

@ -29,7 +29,7 @@ Find S(20 000 000) mod 108.
```yml ```yml
tests: tests:
- text: <code>euler337()</code> should return 85068035. - text: <code>euler337()</code> should return 85068035.
testString: assert.strictEqual(euler337(), 85068035, '<code>euler337()</code> should return 85068035.'); testString: assert.strictEqual(euler337(), 85068035);
``` ```

View File

@ -37,7 +37,7 @@ Find G(1012). Give your answer modulo 108.
```yml ```yml
tests: tests:
- text: <code>euler338()</code> should return 15614292. - text: <code>euler338()</code> should return 15614292.
testString: assert.strictEqual(euler338(), 15614292, '<code>euler338()</code> should return 15614292.'); testString: assert.strictEqual(euler338(), 15614292);
``` ```

View File

@ -29,7 +29,7 @@ Find E(10 000) and give your answer rounded to 6 places behind the decimal point
```yml ```yml
tests: tests:
- text: <code>euler339()</code> should return 19823.542204. - text: <code>euler339()</code> should return 19823.542204.
testString: assert.strictEqual(euler339(), 19823.542204, '<code>euler339()</code> should return 19823.542204.'); testString: assert.strictEqual(euler339(), 19823.542204);
``` ```

View File

@ -32,7 +32,7 @@ Find the last 9 digits of S(217, 721, 127).
```yml ```yml
tests: tests:
- text: <code>euler340()</code> should return 291504964. - text: <code>euler340()</code> should return 291504964.
testString: assert.strictEqual(euler340(), 291504964, '<code>euler340()</code> should return 291504964.'); testString: assert.strictEqual(euler340(), 291504964);
``` ```

View File

@ -28,7 +28,7 @@ Find ΣG(n3) for 1 ≤ n < 106.
```yml ```yml
tests: tests:
- text: <code>euler341()</code> should return 56098610614277016. - text: <code>euler341()</code> should return 56098610614277016.
testString: assert.strictEqual(euler341(), 56098610614277016, '<code>euler341()</code> should return 56098610614277016.'); testString: assert.strictEqual(euler341(), 56098610614277016);
``` ```

View File

@ -28,7 +28,7 @@ Find the sum of all numbers n, 1 &lt n < 1010 such that φ(n2) is a cube.
```yml ```yml
tests: tests:
- text: <code>euler342()</code> should return 5943040885644. - text: <code>euler342()</code> should return 5943040885644.
testString: assert.strictEqual(euler342(), 5943040885644, '<code>euler342()</code> should return 5943040885644.'); testString: assert.strictEqual(euler342(), 5943040885644);
``` ```

View File

@ -41,7 +41,7 @@ Find Σf(k3) for 1 ≤ k ≤ 2×106.
```yml ```yml
tests: tests:
- text: <code>euler343()</code> should return 269533451410884200. - text: <code>euler343()</code> should return 269533451410884200.
testString: assert.strictEqual(euler343(), 269533451410884200, '<code>euler343()</code> should return 269533451410884200.'); testString: assert.strictEqual(euler343(), 269533451410884200);
``` ```

View File

@ -40,7 +40,7 @@ Find W(1 000 000, 100) modulo the semiprime 1000 036 000 099 (= 1 000 003 · 1 0
```yml ```yml
tests: tests:
- text: <code>euler344()</code> should return 65579304332. - text: <code>euler344()</code> should return 65579304332.
testString: assert.strictEqual(euler344(), 65579304332, '<code>euler344()</code> should return 65579304332.'); testString: assert.strictEqual(euler344(), 65579304332);
``` ```

View File

@ -45,7 +45,7 @@ Find the Matrix Sum of:
```yml ```yml
tests: tests:
- text: <code>euler345()</code> should return 13938. - text: <code>euler345()</code> should return 13938.
testString: assert.strictEqual(euler345(), 13938, '<code>euler345()</code> should return 13938.'); testString: assert.strictEqual(euler345(), 13938);
``` ```

View File

@ -25,7 +25,7 @@ Find the sum of all strong repunits below 1012.
```yml ```yml
tests: tests:
- text: <code>euler346()</code> should return 336108797689259260. - text: <code>euler346()</code> should return 336108797689259260.
testString: assert.strictEqual(euler346(), 336108797689259260, '<code>euler346()</code> should return 336108797689259260.'); testString: assert.strictEqual(euler346(), 336108797689259260);
``` ```

View File

@ -34,7 +34,7 @@ Find S(10 000 000).
```yml ```yml
tests: tests:
- text: <code>euler347()</code> should return 11109800204052. - text: <code>euler347()</code> should return 11109800204052.
testString: assert.strictEqual(euler347(), 11109800204052, '<code>euler347()</code> should return 11109800204052.'); testString: assert.strictEqual(euler347(), 11109800204052);
``` ```

View File

@ -29,7 +29,7 @@ Find the sum of the five smallest such palindromic numbers.
```yml ```yml
tests: tests:
- text: <code>euler348()</code> should return 1004195061. - text: <code>euler348()</code> should return 1004195061.
testString: assert.strictEqual(euler348(), 1004195061, '<code>euler348()</code> should return 1004195061.'); testString: assert.strictEqual(euler348(), 1004195061);
``` ```

View File

@ -25,7 +25,7 @@ Starting with a grid that is entirely white, how many squares are black after 10
```yml ```yml
tests: tests:
- text: <code>euler349()</code> should return 115384615384614940. - text: <code>euler349()</code> should return 115384615384614940.
testString: assert.strictEqual(euler349(), 115384615384614940, '<code>euler349()</code> should return 115384615384614940.'); testString: assert.strictEqual(euler349(), 115384615384614940);
``` ```

View File

@ -25,17 +25,17 @@ Circular primes individual rotation can exceeed `n`.
```yml ```yml
tests: tests:
- text: <code>circularPrimes(100)</code> should return 13. - text: <code>circularPrimes(100)</code> should return 13.
testString: assert(circularPrimes(100) == 13, '<code>circularPrimes(100)</code> should return 13.'); testString: assert(circularPrimes(100) == 13);
- text: <code>circularPrimes(100000)</code> should return 43. - text: <code>circularPrimes(100000)</code> should return 43.
testString: assert(circularPrimes(100000) == 43, '<code>circularPrimes(100000)</code> should return 43.'); testString: assert(circularPrimes(100000) == 43);
- text: <code>circularPrimes(250000)</code> should return 45. - text: <code>circularPrimes(250000)</code> should return 45.
testString: assert(circularPrimes(250000) == 45, '<code>circularPrimes(250000)</code> should return 45.'); testString: assert(circularPrimes(250000) == 45);
- text: <code>circularPrimes(500000)</code> should return 49. - text: <code>circularPrimes(500000)</code> should return 49.
testString: assert(circularPrimes(500000) == 49, '<code>circularPrimes(500000)</code> should return 49.'); testString: assert(circularPrimes(500000) == 49);
- text: <code>circularPrimes(750000)</code> should return 49. - text: <code>circularPrimes(750000)</code> should return 49.
testString: assert(circularPrimes(750000) == 49, '<code>circularPrimes(750000)</code> should return 49.'); testString: assert(circularPrimes(750000) == 49);
- text: <code>circularPrimes(1000000)</code> should return 55. - text: <code>circularPrimes(1000000)</code> should return 55.
testString: assert(circularPrimes(1000000) == 55, '<code>circularPrimes(1000000)</code> should return 55.'); testString: assert(circularPrimes(1000000) == 55);
``` ```

View File

@ -33,7 +33,7 @@ Find f(106, 1012, 1018) mod 1014.
```yml ```yml
tests: tests:
- text: <code>euler350()</code> should return 84664213. - text: <code>euler350()</code> should return 84664213.
testString: assert.strictEqual(euler350(), 84664213, '<code>euler350()</code> should return 84664213.'); testString: assert.strictEqual(euler350(), 84664213);
``` ```

View File

@ -39,7 +39,7 @@ Find H(100 000 000).
```yml ```yml
tests: tests:
- text: <code>euler351()</code> should return 11762187201804552. - text: <code>euler351()</code> should return 11762187201804552.
testString: assert.strictEqual(euler351(), 11762187201804552, '<code>euler351()</code> should return 11762187201804552.'); testString: assert.strictEqual(euler351(), 11762187201804552);
``` ```

View File

@ -57,7 +57,7 @@ Give your answer rounded to six decimal places.
```yml ```yml
tests: tests:
- text: <code>euler352()</code> should return 378563.260589. - text: <code>euler352()</code> should return 378563.260589.
testString: assert.strictEqual(euler352(), 378563.260589, '<code>euler352()</code> should return 378563.260589.'); testString: assert.strictEqual(euler352(), 378563.260589);
``` ```

View File

@ -48,7 +48,7 @@ Give your answer rounded to 10 digits behind the decimal point in the form a.bcd
```yml ```yml
tests: tests:
- text: <code>euler353()</code> should return 1.2759860331. - text: <code>euler353()</code> should return 1.2759860331.
testString: assert.strictEqual(euler353(), 1.2759860331, '<code>euler353()</code> should return 1.2759860331.'); testString: assert.strictEqual(euler353(), 1.2759860331);
``` ```

View File

@ -31,7 +31,7 @@ Find the number of L ≤ 5·1011 such that B(L) = 450.
```yml ```yml
tests: tests:
- text: <code>euler354()</code> should return 58065134. - text: <code>euler354()</code> should return 58065134.
testString: assert.strictEqual(euler354(), 58065134, '<code>euler354()</code> should return 58065134.'); testString: assert.strictEqual(euler354(), 58065134);
``` ```

View File

@ -27,7 +27,7 @@ Find Co(200000).
```yml ```yml
tests: tests:
- text: <code>euler355()</code> should return 1726545007. - text: <code>euler355()</code> should return 1726545007.
testString: assert.strictEqual(euler355(), 1726545007, '<code>euler355()</code> should return 1726545007.'); testString: assert.strictEqual(euler355(), 1726545007);
``` ```

View File

@ -27,7 +27,7 @@ Note: represents the floor function.
```yml ```yml
tests: tests:
- text: <code>euler356()</code> should return 28010159. - text: <code>euler356()</code> should return 28010159.
testString: assert.strictEqual(euler356(), 28010159, '<code>euler356()</code> should return 28010159.'); testString: assert.strictEqual(euler356(), 28010159);
``` ```

View File

@ -25,7 +25,7 @@ for every divisor d of n, d+n/d is prime.
```yml ```yml
tests: tests:
- text: <code>euler357()</code> should return 1739023853137. - text: <code>euler357()</code> should return 1739023853137.
testString: assert.strictEqual(euler357(), 1739023853137, '<code>euler357()</code> should return 1739023853137.'); testString: assert.strictEqual(euler357(), 1739023853137);
``` ```

View File

@ -48,7 +48,7 @@ There is only one cyclic number for which, the eleven leftmost digits are 000000
```yml ```yml
tests: tests:
- text: <code>euler358()</code> should return 3284144505. - text: <code>euler358()</code> should return 3284144505.
testString: assert.strictEqual(euler358(), 3284144505, '<code>euler358()</code> should return 3284144505.'); testString: assert.strictEqual(euler358(), 3284144505);
``` ```

View File

@ -49,7 +49,7 @@ Find the sum of all P(f, r) for all positive f and r such that f × r = 71328803
```yml ```yml
tests: tests:
- text: <code>euler359()</code> should return 40632119. - text: <code>euler359()</code> should return 40632119.
testString: assert.strictEqual(euler359(), 40632119, '<code>euler359()</code> should return 40632119.'); testString: assert.strictEqual(euler359(), 40632119);
``` ```

View File

@ -22,13 +22,13 @@ Find the sum of all numbers, less than n, whereas 1000 <= n <= 1000000, which ar
```yml ```yml
tests: tests:
- text: <code>doubleBasePalindromes(1000)</code> should return 1772. - text: <code>doubleBasePalindromes(1000)</code> should return 1772.
testString: assert(doubleBasePalindromes(1000) == 1772, '<code>doubleBasePalindromes(1000)</code> should return 1772.'); testString: assert(doubleBasePalindromes(1000) == 1772);
- text: <code>doubleBasePalindromes(50000)</code> should return 105795. - text: <code>doubleBasePalindromes(50000)</code> should return 105795.
testString: assert(doubleBasePalindromes(50000) == 105795, '<code>doubleBasePalindromes(50000)</code> should return 105795.'); testString: assert(doubleBasePalindromes(50000) == 105795);
- text: <code>doubleBasePalindromes(500000)</code> should return 286602. - text: <code>doubleBasePalindromes(500000)</code> should return 286602.
testString: assert(doubleBasePalindromes(500000) == 286602, '<code>doubleBasePalindromes(500000)</code> should return 286602.'); testString: assert(doubleBasePalindromes(500000) == 286602);
- text: <code>doubleBasePalindromes(1000000)</code> should return 872187. - text: <code>doubleBasePalindromes(1000000)</code> should return 872187.
testString: assert(doubleBasePalindromes(1000000) == 872187, '<code>doubleBasePalindromes(1000000)</code> should return 872187.'); testString: assert(doubleBasePalindromes(1000000) == 872187);
``` ```

View File

@ -31,7 +31,7 @@ Find S(1010).
```yml ```yml
tests: tests:
- text: <code>euler360()</code> should return 878825614395267100. - text: <code>euler360()</code> should return 878825614395267100.
testString: assert.strictEqual(euler360(), 878825614395267100, '<code>euler360()</code> should return 878825614395267100.'); testString: assert.strictEqual(euler360(), 878825614395267100);
``` ```

View File

@ -45,7 +45,7 @@ Find the last 9 digits of .
```yml ```yml
tests: tests:
- text: <code>euler361()</code> should return 178476944. - text: <code>euler361()</code> should return 178476944.
testString: assert.strictEqual(euler361(), 178476944, '<code>euler361()</code> should return 178476944.'); testString: assert.strictEqual(euler361(), 178476944);
``` ```

View File

@ -36,7 +36,7 @@ Find S(10 000 000 000).
```yml ```yml
tests: tests:
- text: <code>euler362()</code> should return 457895958010. - text: <code>euler362()</code> should return 457895958010.
testString: assert.strictEqual(euler362(), 457895958010, '<code>euler362()</code> should return 457895958010.'); testString: assert.strictEqual(euler362(), 457895958010);
``` ```

View File

@ -41,7 +41,7 @@ That is, if L is the length of the curve, calculate 100 × L π/2π/2Give y
```yml ```yml
tests: tests:
- text: <code>euler363()</code> should return 0.0000372091. - text: <code>euler363()</code> should return 0.0000372091.
testString: assert.strictEqual(euler363(), 0.0000372091, '<code>euler363()</code> should return 0.0000372091.'); testString: assert.strictEqual(euler363(), 0.0000372091);
``` ```

View File

@ -32,7 +32,7 @@ Find T(1 000 000) mod 100 000 007.
```yml ```yml
tests: tests:
- text: <code>euler364()</code> should return 44855254. - text: <code>euler364()</code> should return 44855254.
testString: assert.strictEqual(euler364(), 44855254, '<code>euler364()</code> should return 44855254.'); testString: assert.strictEqual(euler364(), 44855254);
``` ```

View File

@ -26,7 +26,7 @@ Calculate ∑M(1018,109,p*q*r) for 1000<p<q<r<5000 and p,q,r prime.
```yml ```yml
tests: tests:
- text: <code>euler365()</code> should return 162619462356610300. - text: <code>euler365()</code> should return 162619462356610300.
testString: assert.strictEqual(euler365(), 162619462356610300, '<code>euler365()</code> should return 162619462356610300.'); testString: assert.strictEqual(euler365(), 162619462356610300);
``` ```

View File

@ -43,7 +43,7 @@ Give your answer modulo 108.
```yml ```yml
tests: tests:
- text: <code>euler366()</code> should return 88351299. - text: <code>euler366()</code> should return 88351299.
testString: assert.strictEqual(euler366(), 88351299, '<code>euler366()</code> should return 88351299.'); testString: assert.strictEqual(euler366(), 88351299);
``` ```

View File

@ -36,7 +36,7 @@ Give your answer rounded to the nearest integer.
```yml ```yml
tests: tests:
- text: <code>euler367()</code> should return 48271207. - text: <code>euler367()</code> should return 48271207.
testString: assert.strictEqual(euler367(), 48271207, '<code>euler367()</code> should return 48271207.'); testString: assert.strictEqual(euler367(), 48271207);
``` ```

View File

@ -33,7 +33,7 @@ Give your answer rounded to 10 digits behind the decimal point.
```yml ```yml
tests: tests:
- text: <code>euler368()</code> should return 253.6135092068. - text: <code>euler368()</code> should return 253.6135092068.
testString: assert.strictEqual(euler368(), 253.6135092068, '<code>euler368()</code> should return 253.6135092068.'); testString: assert.strictEqual(euler368(), 253.6135092068);
``` ```

View File

@ -24,7 +24,7 @@ Find ∑f(n) for 4 ≤ n ≤ 13.
```yml ```yml
tests: tests:
- text: <code>euler369()</code> should return 862400558448. - text: <code>euler369()</code> should return 862400558448.
testString: assert.strictEqual(euler369(), 862400558448, '<code>euler369()</code> should return 862400558448.'); testString: assert.strictEqual(euler369(), 862400558448);
``` ```

View File

@ -22,13 +22,13 @@ NOTE: 2, 3, 5, and 7 are not considered to be truncatable primes.
```yml ```yml
tests: tests:
- text: <code>truncatablePrimes(8)</code> should return 1986. - text: <code>truncatablePrimes(8)</code> should return 1986.
testString: assert(truncatablePrimes(8) == 1986, '<code>truncatablePrimes(8)</code> should return 1986.'); testString: assert(truncatablePrimes(8) == 1986);
- text: <code>truncatablePrimes(9)</code> should return 5123. - text: <code>truncatablePrimes(9)</code> should return 5123.
testString: assert(truncatablePrimes(9) == 5123, '<code>truncatablePrimes(9)</code> should return 5123.'); testString: assert(truncatablePrimes(9) == 5123);
- text: <code>truncatablePrimes(10)</code> should return 8920. - text: <code>truncatablePrimes(10)</code> should return 8920.
testString: assert(truncatablePrimes(10) == 8920, '<code>truncatablePrimes(10)</code> should return 8920.'); testString: assert(truncatablePrimes(10) == 8920);
- text: <code>truncatablePrimes(11)</code> should return 748317. - text: <code>truncatablePrimes(11)</code> should return 748317.
testString: assert(truncatablePrimes(11) == 748317, '<code>truncatablePrimes(11)</code> should return 748317.'); testString: assert(truncatablePrimes(11) == 748317);
``` ```

View File

@ -26,7 +26,7 @@ How many geometric triangles exist with perimeter ≤ 2.5·1013 ?
```yml ```yml
tests: tests:
- text: <code>euler370()</code> should return 41791929448408. - text: <code>euler370()</code> should return 41791929448408.
testString: assert.strictEqual(euler370(), 41791929448408, '<code>euler370()</code> should return 41791929448408.'); testString: assert.strictEqual(euler370(), 41791929448408);
``` ```