Pointer to structure & unions — Study Resources & PYQs
Use of pointers to access and manipulate structures and unions in C.
- Estimated study time: 30 minutes
Study resources
- Structure Pointer in C - GeeksforGeeks (Article) — Shows both ways of accessing members through a pointer: (*ptr).member and ptr->member. Knowing they are equivalent is worth marks.
- Structures and Unions section - GeeksforGeeks tutorial (Article) — Covers struct declaration, initialisation, the dot operator, nested structures and arrays of structures, then unions and enums in the same section.
Taught in these subjects
- COMPUTER PROGRAMMING — CST3101 · Government College of Engineering and Technology, Jammu