test.txt

来自「清华大学计算机系数据结构课程教材《数据结构 用面向对象方法和C++描述》(殷人昆」· 文本 代码 · 共 66 行

TXT
66
字号
+-----------------------------------------------------------+
#1 Construct the sparseMatrix :
pleae input the number of rows , columns and nonzero nodes :
2 2 2
Enter row, column, and value of term:1
0 1 2
Enter row, column, and value of term:2
1 0 4
Construct Succeed!
The SparseMatrix you input is :
rows = 2
cols = 2
Nonzero terms = 2
M[0][1]=2
M[1][0]=4
+------------------------------------------------------------+
#2 Test void Transpose(SparseMatrix<E>& b)
New matrix is :
rows = 2
cols = 2
Nonzero terms = 2
M[0][1]=4
M[1][0]=2

+------------------------------------------------------------+
#3 Test void FastTranspos(SparseMatrix<E>& b)
New matrix is :
rows = 2
cols = 2
Nonzero terms = 2
M[0][1]=4
M[1][0]=2

+------------------------------------------------------------+
#4 Test SparseMatrix<E> Add(SparseMatrix<E>& b)
Input another matrix :
Rows = 2 , Cols = 2 Input the Terms :
2
Enter row, column, and value of term:1
0 0 2
Enter row, column, and value of term:2
0 1 5
The Result is :
rows = 2
cols = 2
Nonzero terms = 3
M[0][0]=2
M[0][1]=7
M[1][0]=4
+------------------------------------------------------------+
#5 Test SparseMatrix<E> Multiply(SparseMatrix<E>& b)
Input another matrix :
Rows = 2 , Cols = 2 Input the Terms :
2
Enter row, column, and value of term:1
0 1 2
Enter row, column, and value of term:2
1 1 4
The Result is :
rows = 2
cols = 2
Nonzero terms = 3
M[0][1]=4
M[1][0]=4
M[-33686019][-572662307]=589843
请按任意键继续. . .

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?