Write a JavaScript function that outputs a rectangle made of stars with variable size, depending on an input parameter. If there is no parameter specified, the rectangle should always be of size 5. Look at the examples to get an idea. The input comes as a single number argument.
Examples:
Input:
1
Output:
*
Input:
2
Output:
**
**
Input:
5
Output:
*****
*****
*****
*****
*****
Input:
Output:
*****
*****
*****
*****
*****
The output is a series of lines printed on the console, forming a rectangle of variable size.