Initialize PA09

++ PA09 Files
++ Makefile for PA09
This commit is contained in:
Charles Descamps 2023-11-05 11:29:51 -07:00
parent ba683c4f44
commit 146e26b5cf
17 changed files with 3832 additions and 0 deletions

View file

@ -0,0 +1,63 @@
// Precompiler directives /////////////////////////////////////////////////////
#ifndef STUDENT_UTILITY_H
#define STUDENT_UTILITY_H
// Header files ///////////////////////////////////////////////////////////////
#include <stdlib.h>
#include <stdio.h>
#include "StandardConstants.h"
#include "GeneralUtility.h"
// global constants ////////////////////////////////////////////////////////////
// None
// data structures /////////////////////////////////////////////////////////////
typedef struct StudentStruct
{
char name[ MAX_STR_LEN ];
int studentId;
char gender;
double gpa;
int priority;
} StudentType;
typedef struct StudentArrayStruct
{
StudentType *array;
int size, capacity;
} StudentArrayType;
/*
Name: deepCopyStudentDAta
Process: copies one StudentType item into another
Function input/parameters: source data (const StudentType)
Function output/parameters: destination data (StudentType *)
Function output/returned: none
Device input/ ---: none
Device output/ ---: none
Dependencies: privateCopyString
*/
void deepCopyStudentData( StudentType *dest, const StudentType source );
/*
Name: studentDataToString
Process: creates display string from all object data
Method input/parameters: none
Method output/parameters: pointer to return string (char * const)
Method output/returned: none
Device input/keyboard: none
Device output/monitor: none
Dependencies: sprintf
*/
void studentDataToString( char *outString, const StudentType toDisplay );
#endif // STUDENT_UTILITY_H