Question: Hi, looking for some help with this problem I'm having in computer science. We use python. This code works well enough -- it prints the
Hi, looking for some help with this problem I'm having in computer science. We use python.

This code works well enough -- it prints the first eight perfect squares as it should -- but it's pretty inelegant. In addition, you've decided it would be better if it could print *any number* of squares. Therefore, you'd like to rewrite this function to take a parameter n, which indicates the number of squares you wish to print, and then it should print those n squares in the same format it now prints the first eight squares
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
