CodeLab Academy 📞 9936 6696
← List Python · Level 8: Nested loops Code · 80 points ← #776 #778 →

#777. Multiply a matrix by 3

Multiply every element of the matrix by 3 and print it. ### Input The first line has n m (the number of rows and columns), each of the next n lines has m integers. ### Output n lines.

Examples

Input
5 2
3 3
7 0
0 5
9 -1
2 0
Output
9 9
21 0
0 15
27 -3
6 0
Input
2 5
-8 5 9 2 4
1 4 -2 2 2
Output
-24 15 27 6 12
3 12 -6 6 6

💡 You can solve it with Python, JavaScript or blocks. Read the input line by line with input(). Don't print a question (like input("Number: ")). Print exactly what the output asks for, nothing more.

🔒 You can solve the first 3 problems without an account. Sign up for free to solve this one!