-->
当前位置:首页 > 题库

PROGRAMMING:Output the product of two matrices

Luz5年前 (2021-05-10)题库384
####Task description
```
Program to output the product of two matrices.
```
####Input format:
```
The first is three positive integers a, B, C (0 〈 a, B, C < 100), which means that the first matrix is row a and column B, and the second matrix is row B and column C.
Then there are a row of integers, B in each row, separated by spaces, representing the contents of the first matrix.
Then there are B-line integers, C in each line, separated by spaces, representing the contents of the second matrix.
```
####Output format:
```
Output the product of two matrices, as a row of integers, each row of C column, integers separated by a space.
```
####Input example:
```in
3 5 2
12 25 56 89 -98
100 200 210 300 2
55 88 66 77 44
1 2
2 2
3 4
5 1
6 2
```
####Output example:
```out
87 191
2642 1744
1078 715
```
####Input example:
```in
2 3 4
1 2 3
3 2 1
1 2 3 4
2 1 2 4
3 2 4 1
```
####Output example:
```out
14 10 19 15
10 10 17 21
```






answer:If there is no answer, please comment