Question: so the answer already given does not fix the issue. a picture of the correct square will be linked, but there should only be a
so the answer already given does not fix the issue. a picture of the correct square will be linked, but there should only be a top line of underscores, and the rest of the underscores will serves as as the bottom line of one line of squares as well as the top line for the next, and the vertical bars should not be double in between, only a single bar. public static char getSquaresint rows, int columns
char square new charrows columns ;
Draw the top line
for int j ; j columns ; j
if j j
squarej;
else
squarej;
Draw the lines between squares and at the bottom
for int i ; i rows ; i
Draw the bottom line
for int j ; j columns ; j
squareij;
Clear the top line for the next row
Arrays.fillsquarei columns ;
return square;
Right now this out puts this
should output this
correct picture of output is provided because the typing is hard
Step by Step Solution
There are 3 Steps involved in it
1 Expert Approved Answer
Step: 1 Unlock
Question Has Been Solved by an Expert!
Get step-by-step solutions from verified subject matter experts
Step: 2 Unlock
Step: 3 Unlock
