mirror of
https://github.com/freeCodeCamp/freeCodeCamp.git
synced 2026-03-26 17:02:27 -04:00
fix(curriculum): Updated the tests to accpet the answer irrespective of the order of concatenation (#54468)
This commit is contained in:
@@ -18,19 +18,19 @@ In your `for...of` loop, use the addition operator to concatenate the `row` valu
|
||||
You should use the concatenation operator on your `result` variable.
|
||||
|
||||
```js
|
||||
assert.match(code, /result\s*\+/);
|
||||
assert.match(code, /(?:result\s*\+|\+\s*result)/);
|
||||
```
|
||||
|
||||
You should concatenate `row` to your `result` variable.
|
||||
|
||||
```js
|
||||
assert.match(code, /result\s*\+\s*row/);
|
||||
assert.match(code, /result\s*\+\s*row|row\s*\+\s*result/);
|
||||
```
|
||||
|
||||
You should assign the result of your concatenation back to the `result` variable.
|
||||
|
||||
```js
|
||||
assert.match(code, /result\s*=\s*result\s*\+\s*row;?/)
|
||||
assert.match(code, /result\s*=\s*(result\s*\+\s*row|row\s*\+\s*result);?/);
|
||||
```
|
||||
|
||||
# --seed--
|
||||
|
||||
Reference in New Issue
Block a user