矩阵加法

You cannot submit for this problem because the contest is ended. You can click "Open in Problem Set" to view this problem in normal mode.

Background

Description

给定两个矩阵(A,B),计算出两个矩阵的和矩阵(C)。将得到的和矩阵进行输出。

Format

Input

第一行输入一个数N(1<=N<=10),表示矩阵是一个N*N的矩阵 之后N行,每行输入N个数,表示A矩阵 再之后N行,每行输入N个数,表示B矩阵

Output

最后,输出一个和矩阵C,表示矩阵A+B的结果 (每个数后都有空格,按照矩阵的形式输出)

Samples

3
1 2 3
4 5 6
7 8 9
1 2 3
4 5 6
7 8 9
2 4 6
8 10 12
14 16 18

Limitation

1s, 1024KiB for each test case.

第七届SWPU-ACM老生预选赛

Not Attended
Status
Done
Rule
ACM/ICPC
Problem
187
Start at
2022-9-19 14:00
End at
2022-10-28 14:00
Duration
936 hour(s)
Host
Partic.
45