1. Write a function that receives an integer x as an argument and print x stars in a line.
For example, if 5 is passed to the function, ***** will be the output.
2. Write a program that asks the user to enter five integers in the range from
1 to 20, and then displays the horizontal bar representation of the input
as illustrated in the example below.
The code I provide below is incomplete but more than enough for you to get started. I also provide 4 different URLs explaining everything you need to know in order to successfully write this program.
#include <iostream>
int main()
{
int UserInput = 0;
std::cin >> UserInput;
for ( int i = 0; i < UserInput; i ++ )
std::cout << "*";
return EXIT_SUCCESS;
}