69,373
社区成员
发帖
与我相关
我的任务
分享
void mul(const int *a, int n1, const int *b, int n2, int *result)
{
for (int i = 0; i < n2; i++)
for (int j = 0; j < n1; j++)
{
result[i + j] = result[i + j] + a[j] * b[i];
result[i + j + 1] = result[i + j + 1] + result[i + j] / 10;
result[i + j] = result[i + j] % 10;
}
}