Skip to content

通过数字生成升序数组

javascript
// Output => [0, 1, 2]
const arr = [...Array(3).keys()];
Comments
  • Latest
  • Oldest
  • Hottest
No comment yet.
Powered by Waline v3.5.6

Views 2890 , Visitors 1705
Released under the MIT License.