1,先在一个.h定义结构体,并申明为外部
如:
struct kkk
{
double dis,bak ;
};
extern struct kkk e;
2、再在使用的文件申明一下
struct
kkk e;
另外一个文件申明为extern struct kkk e;