pp.cpp
来自「关于数据结构的各章节的c原代码实现」· C++ 代码 · 共 38 行
CPP
38 行
// pp.cpp : Defines the entry point for the console application.
//
#include "stdafx.h"
#include <stdio.h>
#include <iostream.h>
void plus(int x[][4],int y[][4],int n){
int i,j;
for (i=0;i<n;i++)
for (j=0;j<4;j++)
x[i][j]+=y[i][j];
}
void prt(int c[][4],int n){
int i,j;
for (i=0;i<n;i++)
{for(j=0;j<4;j++)
cout<<c[i][j]<<" ";
cout<<endl;
}
}
int main(int argc, char* argv[])
{
int a[3][4]={1,2,3,4,5,6,7,8,9,10,11,12};
int b[3][4]={1,2,3,4,5,6,7,8,9,10,11,12};
plus(a,b,3);
prt(a,3);
return 0;
}
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?