Skip to content

Commit

Permalink
Fix a typo
Browse files Browse the repository at this point in the history
  • Loading branch information
linhe0x0 authored May 31, 2017
1 parent 5711430 commit 464e544
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -101,7 +101,7 @@ console.log(resultB); // [1, 2, 3, 5]

现在我们可以多次调用这个函数,且相同的输入获得相同的输出,与预期一致。这是因为我们不再改变 **array** 变量。我们把这个函数叫做“纯函数”。

> **注意:**你还可以使用 **concat**,来代替 **slice****push**
> **注意:** 你还可以使用 **concat**,来代替 **slice****push**
> 即:arrayInput.concat(value);
我们还可以使用 ES6 的[扩展语法](https://developer.mozilla.org/nl/docs/Web/JavaScript/Reference/Operators/Spread_operator),来简化函数。
Expand Down

0 comments on commit 464e544

Please sign in to comment.