CS 3251
CS 3251
70069
B.E/B.TECH.DEGREE
EXAMINATIONS,APRIL/MAY2024
SECOND SEMESTER
COMPUTER SCIENCE AND ENGINEERING
CS 3251 – PROGRAMMING IN C
(Regulations 2021)
4. Sort the following elements using selection sort method 23,55, 16,78,2.
11. (a) Explain the storage classes in 'C' with suitable examples.
Or
(ii) Write a C program to find scaling of two matrices (2D array) which will
be entered by a user. (8)
Or
13. (a) (i) Classify the function prototypes with suitable examples. (8)
Or
(b)(i) Explain the concept of pass by value and pass by reference. Write a
C program to swap the content of two variables using pass by reference.
(8)
(ii) Explain about pointers and write the use of pointers in arrays with
suitable example.(8)
Or
(b) Write a C program to create mark sheet for students using self-
referential structure.
15. (a) (i) Write a C program to get name and marks of 'n' number of
students from user and store them in a file. (8)
(ii) Write a C program to read name and marks of 'n' number of students
from user and store them in a file. If the file previously exits then append
the information into the existing file. (8)
Or
(b) (i) Write a C program to write all the members of an array of structures
to a file using fwrite(). Read the array from the file and display on the
screen. (8)