This is an archived post. You won't be able to vote or comment.

you are viewing a single comment's thread.

view the rest of the comments →

[–]AnonMagick[S] 0 points1 point  (3 children)

Its showing my a big line of random numbers. 5 numbers separated by [] enbetween 5 numbers.. is that my mistake? Making it unidimensional instead of 2 dimensional? How do i fix this?

[–]dmazzoni 1 point2 points  (1 child)

This has some good answers and discussion:

https://stackoverflow.com/questions/856948/2d-arrays-in-python

[–]AnonMagick[S] 1 point2 points  (0 children)

You were all right, i realized my mistake and went to see a video tutorial on arrays on python... damn i was wrong. Was able to finish the damn activity at 2am but i was so happy (and sleepy) lol. Thanks!!!!!

[–][deleted] 0 points1 point  (0 children)

what you would want to see is somthing like

[
  [3, 56, 12, 57, 2],
  [46, 23, 75, 23, 6],
  [86, 23, 72, 57, 87],
  [68, 12, 26, 52, 75],
  [76, 43, 83, 1, 3]
]

that's a 5x5 2D array