Given the following definition of a StudentRecord and
#define's:
typedef struct {
char name[MAX_NAME_LEN];
int stID;
double cse142Grade;
} StudentRecord;
#define LESS -1
#define EQUAL 0
#define GREATER 1
Write a function which:
- Swaps two StudentRecord's (implement this using pointers)
- Compares two StudentRecord's and returns if the first
StudentRecord's is "less", "equal", or "greater" than the
second. How do you determine that one StudentRecord is
"greater" than another? You decide, but make sure you comment your
assumption in the function comment! (for an extra challenge, implement
this using pointers).