Your inner loop is going to control the columns (it's a bit confusing because people usually specify dimensions as m rows by n columns, but you've done the opposite), so the inner (j loop) should go to m and your outer (i loop) loop should go to n.
So your loop hits the first row (i = 0)
Then goes and hits each of the columns (j = 0,1,2,..,m)
Second row (i = 1)
Then each of the m columns again
Etc.
jonsca
Quantitative Phrenologist
5,621 posts since Sep 2009
Reputation Points: 1,165
Solved Threads: 581