/*Structure assignment.*/ #include // define a structure template struct demo { int a; int b; }; int main(void) { struct demo x, y; //x and y are structure variables //initialize structure variable x x.a = 9; x.b = 10; // assign one structure to another, do not need // to assign the value of each member seperately y = x; printf("%d %d\n", y.a, y.b); return 0; }