Compare commits

..

No commits in common. "46cd2556bcf86ae16398d03bde94528df03624c8" and "10fe1747d3b63ca1533ce55b2d3feae8d1e16948" have entirely different histories.

5 changed files with 29 additions and 35 deletions

View File

@ -1,17 +1,14 @@
#include "stdio.h" #include "stdio.h"
void print(char *text) void print(char *text) {
{
printf(text); printf(text);
} }
void println(char *text) void println(char *text) {
{
newline(); newline();
print(text); print(text);
} }
void newline() void newline() {
{
printf("\n"); printf("\n");
} }

View File

@ -58,9 +58,10 @@ int main()
printf("Course of units: %d", first->course_info.no_of_units); printf("Course of units: %d", first->course_info.no_of_units);
read_file("./../data/welcome.txt"); read_file("./../data/welcome.txt");
display_menu(); display_menu();
newline(); newline();
// scanf("\nenter the option: ", selected); // scanf("\nenter the option: ", selected);
@ -103,33 +104,32 @@ void menu(int menu)
} }
} }
void display_menu()
{ void display_menu() {
printf("\n"); printf("\n");
read_file("./../note/section1.txt"); read_file("./../note/section1.txt");
} }
void display_students() void display_students() {
{
} }
void search_student() void search_student() {
{
} }
void find_maximum() void find_maximum() {
{
} }
void find_failed() void find_failed() {
{
} }
void update_file() void update_file() {
{
} }
void exit_program() void exit_program() {
{
println("Goodbye..."); println("Goodbye...");
} }

View File

@ -2,32 +2,26 @@
#include "stdio.h" #include "stdio.h"
#include "./student_tag.h" #include "./student_tag.h"
void display() void display() {
{
printf("display..."); printf("display...");
} }
void search(int mark) void search(int mark) {
{
printf("search mark..."); printf("search mark...");
} }
void find_largest_average() void find_largest_average() {
{
printf("find largest average..."); printf("find largest average...");
} }
void find_failed_students() void find_failed_students() {
{
printf("find failed students..."); printf("find failed students...");
} }
void add_new(struct student_tag student) void add_new(struct student_tag student) {
{
printf("add new..."); printf("add new...");
} }
void quite() void quite() {
{
exit(1); exit(1);
} }

View File

@ -32,4 +32,5 @@ int main()
// show menu // show menu
menu(); menu();
} }

View File

@ -15,6 +15,8 @@ void menu()
printf("\n(6) Quit program\n\n"); printf("\n(6) Quit program\n\n");
} }
void choose_menu(int menu) void choose_menu(int menu)
{ {
@ -33,8 +35,8 @@ void choose_menu(int menu)
find_failed_students(); find_failed_students();
break; break;
case MENU_5: case MENU_5:
struct person_tag info = {"1", "Sambo"}; struct person_tag info = {"1","Sambo"};
struct student_tag std = {.student_info = info}; struct student_tag std = {.student_info = info};
add_new(std); add_new(std);
break; break;