Question: write code in c program. And solve a) and b) exactly. * typedef struct { char name[50]; int id; char dept[20]; double cgpa; } student;
write code in c program. And solve a) and b) exactly. * typedef struct {
char name[50];
int id;
char dept[20]; double cgpa;
} student;
- Write a function void saveByDept(char *fileName, char *deptName , student allStudents[], int size) that will save the information of all students who belong to the department with name pointed to by deptName into a text file. The name of the file is given as an input parameter, filename.
- Write another function to delete the students of the department with a CGPA greater than or equal to 3 from the file you have created in part (a).
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
