Feat: add new Markdown parser (#39800)
and change all the challenges to new `md` format.
This commit is contained in:
committed by
GitHub
parent
a07f84c8ec
commit
0bd52f8bd1
@ -1,48 +1,35 @@
|
||||
---
|
||||
id: 5900f4e01000cf542c50fff2
|
||||
challengeType: 5
|
||||
title: 'Problem 371: Licence plates'
|
||||
challengeType: 5
|
||||
forumTopicId: 302033
|
||||
---
|
||||
|
||||
## Description
|
||||
<section id='description'>
|
||||
Oregon licence plates consist of three letters followed by a three digit number (each digit can be from [0..9]).
|
||||
While driving to work Seth plays the following game:
|
||||
Whenever the numbers of two licence plates seen on his trip add to 1000 that's a win.
|
||||
# --description--
|
||||
|
||||
Oregon licence plates consist of three letters followed by a three digit number (each digit can be from \[0..9]).
|
||||
|
||||
While driving to work Seth plays the following game:
|
||||
|
||||
Whenever the numbers of two licence plates seen on his trip add to 1000 that's a win.
|
||||
|
||||
E.g. MIC-012 and HAN-988 is a win and RYU-500 and SET-500 too. (as long as he sees them in the same trip).
|
||||
|
||||
|
||||
Find the expected number of plates he needs to see for a win.
|
||||
Give your answer rounded to 8 decimal places behind the decimal point.
|
||||
|
||||
Find the expected number of plates he needs to see for a win. Give your answer rounded to 8 decimal places behind the decimal point.
|
||||
|
||||
Note: We assume that each licence plate seen is equally likely to have any three digit number on it.
|
||||
</section>
|
||||
|
||||
## Instructions
|
||||
<section id='instructions'>
|
||||
# --hints--
|
||||
|
||||
</section>
|
||||
|
||||
## Tests
|
||||
<section id='tests'>
|
||||
|
||||
```yml
|
||||
tests:
|
||||
- text: <code>euler371()</code> should return 40.66368097.
|
||||
testString: assert.strictEqual(euler371(), 40.66368097);
|
||||
`euler371()` should return 40.66368097.
|
||||
|
||||
```js
|
||||
assert.strictEqual(euler371(), 40.66368097);
|
||||
```
|
||||
|
||||
</section>
|
||||
# --seed--
|
||||
|
||||
## Challenge Seed
|
||||
<section id='challengeSeed'>
|
||||
|
||||
<div id='js-seed'>
|
||||
## --seed-contents--
|
||||
|
||||
```js
|
||||
function euler371() {
|
||||
@ -53,17 +40,8 @@ function euler371() {
|
||||
euler371();
|
||||
```
|
||||
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
</section>
|
||||
|
||||
## Solution
|
||||
<section id='solution'>
|
||||
# --solutions--
|
||||
|
||||
```js
|
||||
// solution required
|
||||
```
|
||||
|
||||
</section>
|
||||
|
Reference in New Issue
Block a user