#include<iostream>
#include<stdio.h>
#include<string>
#define swap(a,b){\
int c;\
c=a;\
a=b;\
b=c;\
}
using namespace std;
int main()
{
int i, j, a[10], b[10];
cout << "输入十个数子在a中" << endl;
for (i = 0; i < 10; i++)
cin >> a[i];
cout << "输入十个数到b中" << endl;
for (j = 0; j < 10; j++)
cin >> b[j];
cout << "显示十个数" << endl;
cout << "显示a" << endl;
for (i = 0; i < 10; i++)
cout << a[i];
cout << "输出b" << endl;
for (j = 0; j < 10; j++)
cout << b[j];
cout << "实现值的互换" << endl;
for (i = 0; i < 10; i++)
swap(a[i], b[i]);
cout << "变换后的值" << endl;
cout << "a的值" << a << endl;
cout << "b的值" << b << endl;
system("pause");
return 0;
}