Talk:Core JavaScript 1.5 Reference:Global Objects:Array:map
From MDC
Couldn't the toUpperCase example be simplified as:
var strings = ["hello", "Array", "WORLD"]; var uppers = strings.map(String.toUpperCase);
- I think the point was to demonstrate the use of a custom function with
map. It ought to be a little less trivial though. --Nickolay 07:20, 4 June 2007 (PDT)
- Is the change I just made a little less trivial enough? (Do please pardon my attempt at humor.) An example with
thisObjectspecified would be good if we could come up with one that made sense, but I don't have time to invest in deep thought over it. :-) --Waldo 23:34, 5 June 2007 (PDT)
- Is the change I just made a little less trivial enough? (Do please pardon my attempt at humor.) An example with