You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
|
//6.2.4.3数组参数.cpp
|
|
#include <iostream>
|
|
|
|
using namespace std;
|
|
|
|
void ass(int (&a)[4]);
|
|
|
|
int main(){
|
|
int a[]={12,222,3,44};
|
|
ass(a);
|
|
return 0;
|
|
}
|
|
|
|
void ass(int (&a)[4]){//这里必须指明维度
|
|
cout << a[0] << endl;
|
|
}
|
|
|