problemscpp
A collection of my answers to algorithm problems in c++.
载入中...
搜索中...
未找到
acwing::acwing813类 参考

AcWing 813. 打印矩阵 更多...

#include <acwing.h>

静态 Public 成员函数

static int main (istream &cin, ostream &cout)
 
static void print2D (int a[][100], int row, int col, ostream &cout)
 

详细描述

AcWing 813. 打印矩阵

在文件 acwing.h1420 行定义.

成员函数说明

◆ main()

int acwing::acwing813::main ( istream & cin,
ostream & cout )
static

在文件 acwing.cpp4535 行定义.

4535 {
4536 int row;
4537 int col;
4538 cin >> row >> col;
4539 int arr[100][100];
4540 for(int i = 0; i < row; i++) {
4541 for(int j = 0; j < col; j++) {
4542 cin >> arr[i][j];
4543 }
4544 }
4545 print2D(arr, row, col, cout);
4546 return 0;
4547 }
static void print2D(int a[][100], int row, int col, ostream &cout)

引用了 print2D().

被这些函数引用 acwing::TEST().

◆ print2D()

void acwing::acwing813::print2D ( int a[][100],
int row,
int col,
ostream & cout )
static

在文件 acwing.cpp4526 行定义.

4526 {
4527 for(int i = 0; i < row; i++) {
4528 for(int j = 0; j < col; j++) {
4529 cout << a[i][j] << " ";
4530 }
4531 cout << endl;
4532 }
4533 }

被这些函数引用 main().


该类的文档由以下文件生成: