News for hackers. Stuff that matters.
Re:Golang landmines by loevborg on Sunday September 18, 2016 @05:48AM (#12524632)
Same in javascript:

    var fns=[];
    for (var i=0; i<3; i++) {
       fns.push(function(){return i});
    };
    fns.map(function(x) { return x.call(); });
Returns

    [ 3, 3, 3 ]

There are no comments on this comment yet.