标签:
ES6 function f (x, y, ...a) { return (x + y) * a.length } f(1, 2, "hello", true, 7) === 9 ES5 function f (x, y) { var a = Array.prototype.slice.call(arguments, 2); return (x + y) * a.length; }; f(1, 2, "hello", true, 7) === 9;
标签:
原文地址:http://www.cnblogs.com/douglasvegas/p/5899854.html