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,33 @@
|
||||
---
|
||||
id: 5900f42b1000cf542c50ff3e
|
||||
challengeType: 5
|
||||
title: 'Problem 191: Prize Strings'
|
||||
challengeType: 5
|
||||
forumTopicId: 301829
|
||||
---
|
||||
|
||||
## Description
|
||||
<section id='description'>
|
||||
# --description--
|
||||
|
||||
A particular school offers cash rewards to children with good attendance and punctuality. If they are absent for three consecutive days or late on more than one occasion then they forfeit their prize.
|
||||
|
||||
During an n-day period a trinary string is formed for each child consisting of L's (late), O's (on time), and A's (absent).
|
||||
|
||||
Although there are eighty-one trinary strings for a 4-day period that can be formed, exactly forty-three strings would lead to a prize:
|
||||
|
||||
OOOO OOOA OOOL OOAO OOAA OOAL OOLO OOLA OAOO OAOA
|
||||
OAOL OAAO OAAL OALO OALA OLOO OLOA OLAO OLAA AOOO
|
||||
AOOA AOOL AOAO AOAA AOAL AOLO AOLA AAOO AAOA AAOL
|
||||
AALO AALA ALOO ALOA ALAO ALAA LOOO LOOA LOAO LOAA
|
||||
LAOO LAOA LAAO
|
||||
OOOO OOOA OOOL OOAO OOAA OOAL OOLO OOLA OAOO OAOA OAOL OAAO OAAL OALO OALA OLOO OLOA OLAO OLAA AOOO AOOA AOOL AOAO AOAA AOAL AOLO AOLA AAOO AAOA AAOL AALO AALA ALOO ALOA ALAO ALAA LOOO LOOA LOAO LOAA LAOO LAOA LAAO
|
||||
|
||||
How many "prize" strings exist over a 30-day period?
|
||||
</section>
|
||||
|
||||
## Instructions
|
||||
<section id='instructions'>
|
||||
# --hints--
|
||||
|
||||
</section>
|
||||
|
||||
## Tests
|
||||
<section id='tests'>
|
||||
|
||||
```yml
|
||||
tests:
|
||||
- text: <code>euler191()</code> should return 1918080160.
|
||||
testString: assert.strictEqual(euler191(), 1918080160);
|
||||
`euler191()` should return 1918080160.
|
||||
|
||||
```js
|
||||
assert.strictEqual(euler191(), 1918080160);
|
||||
```
|
||||
|
||||
</section>
|
||||
# --seed--
|
||||
|
||||
## Challenge Seed
|
||||
<section id='challengeSeed'>
|
||||
|
||||
<div id='js-seed'>
|
||||
## --seed-contents--
|
||||
|
||||
```js
|
||||
function euler191() {
|
||||
@ -53,17 +38,8 @@ function euler191() {
|
||||
euler191();
|
||||
```
|
||||
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
</section>
|
||||
|
||||
## Solution
|
||||
<section id='solution'>
|
||||
# --solutions--
|
||||
|
||||
```js
|
||||
// solution required
|
||||
```
|
||||
|
||||
</section>
|
||||
|
Reference in New Issue
Block a user