一道C数据结构题目

2024-12-27 21:18:00
推荐回答(1个)
回答1:

#define ROW_A 4
#define COLUMN_A 5
#define ROW_B 5
#define COLUMN_B 7

Multiply (matrix_a, matrix_b, matrix_c)
{
int a_row, temp_dim, b_column;
for (a_row = 0; a_row < ROW_A; a_row++)
for (b_column = 0; b_column < COLUMN_B; b_column++)
{
matrix[a_row][b_column] = 0;
for (temp_dim = 0; temp_dim < COLUMN_A; temp_dim++)
{
matrix[a_row][b_column] += matrix[a_row][temp_dim] * matrix[temp_dim][b_column];
}
}

}
差不多是这样了,你再好好看看书吧