mirror of
https://github.com/freeCodeCamp/freeCodeCamp.git
synced 2026-01-13 18:02:59 -05:00
297 B
297 B
title, localeTitle
| title | localeTitle |
|---|---|
| Manipulate Arrays With push() | 用push()操纵数组 |
用push()操纵数组
push()方法允许您将元素追加(添加到末尾)到数组。像这样......
var arr = [1, 2, 3, 4];
arr.push(5); // Now, the array is [1, 2, 3, 4, 5]