How to repeat a string N number of times in JavaScript

Опубликовано: 02 Октябрь 2024
на канале: Suraj Sharma - Full Stack Developer
475
7

This video is about writing a Javascript program to repeat a string 'n' number of times without using a built-in function.

I have discussed two ways to repeat a string in Javascript
1. Using a recursively function,
2. using a ES6 built-in function String.prototype.repeat(count)

Get free access to tutorials on Python and JavaScript in my blog
https://surajsharma.net/blog/repeat-s...