mirror of
https://github.com/kmc7468/cs420.git
synced 2025-12-16 07:28:52 +00:00
Reorganize tests
This commit is contained in:
16
examples/c/array2.c
Normal file
16
examples/c/array2.c
Normal file
@@ -0,0 +1,16 @@
|
||||
void init(int row, int col, int a[4][5]) {
|
||||
for (int i = 0; i < row; i++) {
|
||||
for (int j = 0; j < col; j++) {
|
||||
a[i][j] = i * j;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
int main() {
|
||||
int a[4][5];
|
||||
int row = 4, col = 5;
|
||||
|
||||
init(row, col, a);
|
||||
|
||||
return a[2][3] == 6;
|
||||
}
|
||||
Reference in New Issue
Block a user