Using for loops and using the same techniques as the pyramid function, create a textsquare function that

Question:

Using for loops and using the same techniques as the pyramid function, create a textsquare function that takes in two values as input: the character to use in making the square, and the size of the square in characters. Then print out a square of that many characters.

>>> textsquare("t",5)
ttttt
t    t
t    t
t    t
ttttt

Fantastic news! We've Found the answer you've been seeking!

Step by Step Answer:

Related Book For  book-img-for-question
Question Posted: