screen output questions of Python
I got a question of displaying my output data. Here is my code:
coordinate = []
z=0
while z <= 10:
y = 0
while y < 10:
x = 0
while x < 10:
coordinate.append((x,y,z))
x += 1
coordinate.append((x,y,z))
y += 1
coordinate.append((x,y,z))
z += 1
for point in coordinate:
print(point)
My output data contains the comma and parenthesis which are supposed to
get rid of. I want my output looks like:0 0 0\n 1 0 0\n 2 0 0\n etc. No
comma and parenthesis, just the values.
No comments:
Post a Comment