JavaScript 字符串乘法函数封装 String.prototype.multiplyTimes = function(n) { return Array.prototype.join.call({length:n+1}, this); };