int型指针数组和char型指针数组的问题
#include <iostream>using namespace std;
int main()
{
int *a[2];
int i=1,j=2;
a[0]=&i;
a[1]=&j;
const char *b[3]={"a","b","c"};
cout<<*a[0]<<endl;
cout<<a[0]<<endl;//此时输出a[0]是地址
cout<<*b[0]<<endl;
cout<<b[0]<<endl;//为什么b[0]输出的不是地址而是字符呢
return 0;
}