Hollow square program

siimnurges at gmail.com siimnurges at gmail.com
Wed Dec 12 12:22:30 EST 2012


Well, I did some modifications and got a hollow square, but the columns aren't perfectly aligned with the rows (at least if input is 5. Thanks for the help :)

rows = int(input())
s1="* "*rows
s2="*"+(rows-2)*" "+"*"
print(s1)
for s in range(rows-2):
    print(s2)
print(s1)



More information about the Python-list mailing list