数据对象:简单变量 int *ps = new int;
访问指针内容:*ps;
数组 int * ps = new int[10];
访问数组元素:ps[0],ps[1]....
结构 inflatable* ps = new inflatable;
访问成员:ps->price
或者(*ps).volume
struct inflatable
{
chan name[20];
float volume;
double price;
}
数据对象:简单变量 int *ps = new int;
访问指针内容:*ps;
数组 int * ps = new int[10];
访问数组元素:ps[0],ps[1]....
结构 inflatable* ps = new inflatable;
访问成员:ps->price
或者(*ps).volume
struct inflatable
{
chan name[20];
float volume;
double price;
}