Skip to content

Commit

Permalink
Update preallocation.md
Browse files Browse the repository at this point in the history
  • Loading branch information
Kikobeats committed Mar 18, 2018
1 parent 78dc435 commit 3a471e9
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion docs/array/preallocation.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ If you want to preallocate an array with a initial value, you can use [`Array.fr

```js
const n = 5
Array.from({length: n}, (value, index) => index);
Array.from({length: n}, (value, index) => index)
// [ 0, 1, 2, 3, 4 ]
```

Expand Down

0 comments on commit 3a471e9

Please sign in to comment.