Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR CPP

1d array

//y * rows + x

for(int y = 0; y < rows; y++)
{
    for(int x = 0; x < cols; x++)
    {
        int point = grid[y * rows + x];
    }
}
Source by stackoverflow.com #
 
PREVIOUS NEXT
Tagged: #array
ADD COMMENT
Topic
Name
3+3 =