SyntaxFix
Write A Post
Hire A Developer
Questions
int rows = 5; int cols = 10; int[] multD = new int[rows * cols]; for (int r = 0; r < rows; r++) { for (int c = 0; c < cols; c++) { int index = r * cols + c; multD[index] = index * 2; } }
Enjoy!