Not implementation on functions

But just put the menu
This commit is contained in:
Sambo Chea 2020-08-02 18:02:35 +07:00
parent 227c5e896d
commit 284a856634

View File

@ -58,13 +58,33 @@ int main(void)
display_menu(); display_menu();
printf("Enter your option: ");
scanf("%d", &selected);
switch (selected)
{
case 1:
display_students(); display_students();
break;
int c = count(); case 2:
search_student();
printf("Count: %d", c); break;
case 3:
printf("\nGoodbye!"); find_maximum();
break;
case 4:
find_failed();
break;
case 5:
update_file();
break;
case 6:
quite();
break;
default:
printf("cannot find your option!");
break;
}
} }
void print_welcome() void print_welcome()
@ -120,12 +140,6 @@ void add_student(char *student_name, char *student_id, char *course_name, int no
} }
} }
void update_file()
{
FILE *file;
file = fopen(FILE_STUDENT_DATA_PATH, "a");
}
void read_student_to_data() void read_student_to_data()
{ {
// init head to null // init head to null
@ -226,3 +240,36 @@ int count()
return n; return n;
} }
void search_student()
{
printf("\nNot implement yet!");
}
void find_maximum()
{
printf("\nNot implement yet!");
}
void find_failed()
{
printf("\nNot implement yet!");
}
void update_file()
{
FILE *file;
file = fopen(FILE_STUDENT_DATA_PATH, "a");
printf("\nNot implement yet!");
}
void read_file()
{
printf("\nNot implement yet!");
}
void quite()
{
printf("\nGoodbye!");
exit(EXIT_SUCCESS);
}