function repeatStringNumTimes(str, num) { if (num < 1) { return ""; } else { return str + repeatStringNumTimes(str, num - 1); } }