In terms of syntax both are similar....
But main difference is in terms of memory management...
In structure.. All members occupy memory and u can assign value to all or few of them... i.e a structure variable will have all data members.
In union... Memory is allocated for largest member and u can assign or use ONLY ONE of many members...
Say u have members as:
And u declare struct a myVar;
Then size is 4+1+8
While for union with similar declaration only max memory ie 8 byte will be allocated..... Cause double occupies max memory out of the three....
And then u can store value for 1 member only... either for int or char or double