Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

In your program perform functions to addStudent(), addCourse(), calculateStudentCourseGrade(), calculateStudentGPA(), displayStudentInfo(), displayCourseInfo(), printClass() and calculateCourseAverage(). Please remember that you are not allowed to use any

image text in transcribed

In your program perform functions to addStudent(), addCourse(), calculateStudentCourseGrade(), calculateStudentGPA(), displayStudentInfo(), displayCourseInfo(), printClass() and calculateCourseAverage(). Please remember that you are not allowed to use any global variables. All variables used must be local variables. Please detail variables as they appear in memory using a diagram. Please provide your flowcharts and technical explanations to the programs along with well documented source code files.

Inside the main() function, along with other variables you need, use the variable courses_t courseClass; to both populate the class data and student data, as well as to display them. Please note that a student cannot get a grade below 0 or a grade above 100 for any test and your program must make sure that input given by user is within the range. Please also note that letter grades are

AA is 4.00 and awarded for a grade 100 90

, BA is 3.5 and awarded for a grade 85 89,

BB is 3.00 and awarded for a grade 84 80,

CB is 2.50 and awarded for a grade 79 75,

CC is 2.00 and awarded for a grade 74 70, DC is 1.50 and awarded for a grade 69 60,

DD is 1.00 and awarded for a grade 59 50

and FF is 0.00 and awarded for a grade 49 0.

The GPA must be between 0.00 to 4.00 and should always be displayed in the correct format.

Write a C program using the macro definitions and structure definitions as detailed below to store data for courses offered at a department at a university and the record of students registered to these courses. #define CLASSSIZE 35 // SINIFKAPASITE #define STUDENTNUMBERLENGTH 10 // OGRENCINUMARAUZUNLUGU #define NAMELENGTH 25 // ADIUZUNLUGU #define COURSENAMELENGTH 50 // DERSADIUZUNLUGU #define COURSECODELENGTH 10 // DERSKODUZUNLUGU #define COURSESREGISTERED 5 // KAYITLIDERSLER #define MIDTERMWEIGHT 30 // VIZEAGIRLIK #define FINALWEIGHT 30 // FINALAGIRLIK #define QUIZWEIGHT 20 // QUIZAGIRLIK #define HOMEWORKWEIGHT 20 // ODEVAGIRLIK typedef struct fullName{ //tam adi char *name; //adi char *surname; 1/soyadi }name_t; typedef struct examGrades{ //sinav not double midterm; //vize double final; 1/final double quiz; //quiz double homework; //odev }grades_t; typedef struct courseRegistered{ //kayitliDersler char courseName [COURSENAMELENGTH]; //ders adi char courseCode [COURSECODELENGTH]; //ders kodu grades_t grades; /otler char letterGrade[2]; //herf notu double numericGrade; /umerik notu } courseReg_t; typedef struct studentInfo{ //ogrenci bilgi name_t studentName; 1/ogrenci adi char *stNo; //ogrenci numara courseReg_t *courses [COURSESREGISTERED]; //dersler double gpa; 1/ortalama }student_t; typedef struct courseInfo{ //ders bilgi char courseName [COURSENAMELENGTH]; //ders adi char courseCode [COURSECODELENGTH]; //ders kodu student_t students [CLASSSIZE]; 1/ogrenciler double courseAverage; //ders ortalama } courses_t; Write a C program using the macro definitions and structure definitions as detailed below to store data for courses offered at a department at a university and the record of students registered to these courses. #define CLASSSIZE 35 // SINIFKAPASITE #define STUDENTNUMBERLENGTH 10 // OGRENCINUMARAUZUNLUGU #define NAMELENGTH 25 // ADIUZUNLUGU #define COURSENAMELENGTH 50 // DERSADIUZUNLUGU #define COURSECODELENGTH 10 // DERSKODUZUNLUGU #define COURSESREGISTERED 5 // KAYITLIDERSLER #define MIDTERMWEIGHT 30 // VIZEAGIRLIK #define FINALWEIGHT 30 // FINALAGIRLIK #define QUIZWEIGHT 20 // QUIZAGIRLIK #define HOMEWORKWEIGHT 20 // ODEVAGIRLIK typedef struct fullName{ //tam adi char *name; //adi char *surname; 1/soyadi }name_t; typedef struct examGrades{ //sinav not double midterm; //vize double final; 1/final double quiz; //quiz double homework; //odev }grades_t; typedef struct courseRegistered{ //kayitliDersler char courseName [COURSENAMELENGTH]; //ders adi char courseCode [COURSECODELENGTH]; //ders kodu grades_t grades; /otler char letterGrade[2]; //herf notu double numericGrade; /umerik notu } courseReg_t; typedef struct studentInfo{ //ogrenci bilgi name_t studentName; 1/ogrenci adi char *stNo; //ogrenci numara courseReg_t *courses [COURSESREGISTERED]; //dersler double gpa; 1/ortalama }student_t; typedef struct courseInfo{ //ders bilgi char courseName [COURSENAMELENGTH]; //ders adi char courseCode [COURSECODELENGTH]; //ders kodu student_t students [CLASSSIZE]; 1/ogrenciler double courseAverage; //ders ortalama } courses_t

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Fundamentals Of Database Management Systems

Authors: Mark L. Gillenson

3rd Edition

978-1119907466

Students also viewed these Databases questions

Question

What is focal length? Explain with a diagram and give an example.

Answered: 1 week ago

Question

What is physics and how does it apply in daily life?

Answered: 1 week ago

Question

Why is the System Build Process an iterative process?

Answered: 1 week ago