function repeatStringNumTimes(string,times){
if(times<=0){
return "";
}
if(times===1){
return string;
else
return string+repeatStringNumTimes(string,times--);
alert(repeatStringNumTimes("abc",3));
皈依舞
相关分类