Jul-11-2019, 01:34 AM
I would use join. Also, it is better to loop directly over the list rather than over the indexes of the list:
for row in R: print(' '.join(row))If you haven't covered the join string method and aren't allowed to use it, you could build the string up piece by piece, rather than printing it piece by piece. Then at the end of the inner loop, print the stripped version of it to get rid of the trailing space.
Craig "Ichabod" O'Brien - xenomind.com
I wish you happiness.
Recommended Tutorials: BBCode, functions, classes, text adventures
I wish you happiness.
Recommended Tutorials: BBCode, functions, classes, text adventures