There are two ways to create a matrix using numpy, one is to create a matrix directly using numpy library, and the other is to create a matrix using array.
Import numbers first:
(1) Import number
(2) from numpy import *
(3) import numpy as np
Related recommendation: Python Basic Course
Then use the above two methods to construct a 4×3 matrix, as shown in the figure: