Complete the code to take the input as an integer and output a square of "*" characters.
An input can be taken by using the following line. You will learn more about inputs in the next session.
val = int(input())
For example, if the input is 2 and 5 respectively:
For example:
val = int(input())
for x in range (0, val):
print('*',end='')
An input can be taken by using the following line. You will learn more about inputs in the next session.
val = int(input())
For example, if the input is 2 and 5 respectively:
For example:
| Input | Result |
|---|---|
| 2 | ** ** |
| 5 | ***** ***** ***** ***** ***** |
for x in range (0, val):
print('*',end='')