求助:自己编的一个小程序!
#include"iostream.h"
void main()
{const int n=10;
int a[n],i=0;
for(int *p=a;p<a+n;p++)
*p=i++;
i=0;
for(*p=a;p<a+n;p++)
cout<<"a["<<i++<<"]="<<*p<<" ";
cout<<endl;}
时出现了一个错误:
C:\Documents and Settings\xue\桌面\111.cpp(8) : error C2440: '=' : cannot convert from 'int [10]' to 'int'
This conversion requires a reinterpret_cast, a C-style cast or function-style cast
Error executing cl.exe.
请多多指教!!!