Created
August 5, 2018 23:20
-
-
Save brennancheung/2398dacdf1dac560fd2dc79dc0287c71 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| let newArr = [] | |
| for (let i = 0; i < arr.length; i++) { | |
| let item = arr[i] | |
| let newValue = fn(item) | |
| newArr.push(newValue) | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment