#include<iostream.h> #include<string.h> struct information{ unsigned long int id; char name[10]; int kg; float price; char made[10]; int year,month,day; int count; }infor1,infor2; void main() { information *ptr1=&infor1,*ptr2=&infor2; cout<<"please input id,name,kg,price,made,year,month,day,count by order"<<endl; cin>>ptr1->id>>ptr1->name>>ptr1->kg>>ptr1->price>>ptr1->made>>ptr1->year>>ptr1->month>>ptr1->day>>ptr1->count; cout<<"this product's information is"<<ptr1->id<<' '<<ptr1->name<<' '<<ptr1->kg<<' '<<ptr1->price<<' '<<ptr1->made<<' '<<ptr1->year<<' '<<ptr1->month<<' '<<ptr1->day<<' '<<ptr1->count<<endl; }