College Management System
College Management System
College Management System
SYSTEM
Under Supervision of/ Dr. Zakaria Abdeltawab
DEPARTMENT/MECHATRONICS
Team Members:-
1-Youssef Mahmoud Ahmed
2- Omar Basem AbdelSalam
3-Ali Mohammed Mohammed
4- Nejm Mohammed
5- AbdelAziz Hazem
6- Mohammed Wasim
7- Mohamed Ahmed Said
Introduction
The College Management System is a simple C program designed to store and
retrieve information about students. The program uses structures to represent
student records and offers options to search for students based on their seat
number or name.
Code Overview
1. Structure Definition: -
This line includes the header file <string.h>, which provides functions for
manipulating strings.
• Define Structure (struct Students):
2. Data Initialization: -
• strcpy Function:
The strcpy function is used to copy strings. It copies the content of the specified
string ("Youssef Mahmoud", "Very Good", etc.) into the corresponding name and
degree members of each student.
• Assigning Values:
For each student (student_1 to student_7), you assign values to their respective
members:
name: The name of the student.
degree: The degree achieved by the student.
age: The age of the student.
seat_num: The seat number of the student.
This part of the code initializes the information for each student.
These Variables are declared to manage user input during the search process.
4. Searching by Student Number in List: -
The code initiates an infinite loop, ensuring continuous interaction until explicitly
broken.
• User Prompt (printf and scanf):
The program prompts the user to enter the search type, specifically whether they
want to search by student number or name.
The user's choice is stored in the search variable.
6. User Interaction
• User Prompt (printf and scanf):
The user is prompted with the question, "Do you want to perform another
operation? (y/n): ".
The user's response is stored in the variable quit.
The return 0; statement is used to gracefully exit the program with a status code
of 0.
A status code of 0 typically indicates a successful execution.
Output on Console
Benefits of the Code