TheOdinProject / javascript-exercises

MIT License
1.18k stars 30.27k forks source link

Update repeatString-solution.js #449

Closed Rezy-Dev closed 1 month ago

Rezy-Dev commented 1 month ago

Because

In the solution file, a new alternative solution has been added as a comment. The solution utilizes the repeat() string method in JavaScript to repeat a given string a specified number of times. This approach simplifies the code by directly leveraging the built-in functionality of the repeat() method instead of manually implementing a loop. By including this alternative solution, the solution file offers learners multiple options to achieve the desired outcome, allowing them to choose the approach that best fits their preferences and requirements.

This PR

Issue

Closes #XXXXX

Additional Information

Pull Request Requirements