Question about arrays

Started by
10 comments, last by jimywang 20 years, 11 months ago
You could simply create an array with just one dimension instead of two or more. Let''s say you have a 200x300 array ([200][300]), you could access, say, [100][50] via...

MyArray[(200*50)+100]
Advertisement
is there any speed benefit from having an array of arrays over a 2d array?

ie: *(ptr+j) instead of arr[j]<br><br> </i>

This topic is closed to new replies.

Advertisement