Question Bank
Programming in C 1BEIT105
B. E. 1st Semester ‘A’ Division (2025-26)
Module 5
1. Define a structure in C. Explain the different types of structure declarations with examples.
2. Describe a method to compare two structure variables of the same type, and provide a simple example.
3. Define a structure with a name student. Develop a C program that uses a structure named student. The
program should read and display the details of ‘N’ students, compute the average marks of the class, and
identify the students who have scored marks above and below the class average
4. Compare the structure and union in terms of syntax, storage and uses/applicability.
5. Define Enumerated data type. Explain the declaration and access of enumerated data types with the help
of C program segment.
6. Develop a C program to access and modify the members of structures, in array of structures in C.
7. Explain arrays of structures and nested structures with complete programs.
8. Explain unions in detail. Compare with structures. Illustrate memory allocation with example.
9. Explain bit-fields with syntax, example, advantages, and limitations.
10. Explain enumerations in C. Write a program using enum to represent days of a week.
11. Discuss typedef in detail. Explain how it improves code readability and portability.
12. Explain the role of sizeof operator in ensuring portability of programs. Illustrate with examples.
13. Write a C program using structure pointers to store and display employee details.
14. Write a C program that uses:
a. Structure containing array
b. Structure within structure
15. Explain passing structures to functions With suitable programs:
a. Call by value
b. Call by reference