fix(curriculum): switch from getUserInput to code (#48676)

pull/48684/head
Lasse Jørgensen 2022-12-07 08:39:57 +01:00 committed by GitHub
parent bafcaaa17d
commit 25c257f4c8
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 3 additions and 3 deletions

View File

@ -41,13 +41,13 @@ Rewrite the `myConcat` function which appends contents of `arr2` to `arr1` so th
You should replace the `var` keyword.
```js
(getUserInput) => assert(!getUserInput('index').match(/var/g));
assert.notMatch(code, /var/g);
```
`myConcat` should be a constant variable (by using `const`).
```js
(getUserInput) => assert(getUserInput('index').match(/const\s+myConcat/g));
assert.match(code, /const\s+myConcat/g);
```
`myConcat` should be an arrow function with two parameters
@ -68,7 +68,7 @@ assert.deepEqual(myConcat([1, 2], [3, 4, 5]), [1, 2, 3, 4, 5]);
The `function` keyword should not be used.
```js
(getUserInput) => assert(!getUserInput('index').match(/function/g));
assert.notMatch(code, /function/g);
```
# --seed--