// ES5 var posNums = nums.filter(function (x) { return x > 0; }); // #ES6 var posNums = nums.filter(x => x > 0); #javascript #tip
0
3
3
0
0