islo zapisei =% d n", i); 0;
} save (void)
{i, k; student * ptr;
char * c; * pti; * fl;
if ((fl = fopen ("bdd.txt", "w")) == NULL)
{("bdd.txt"); -1;
} (ctrl.nb == 0)
{("Baza dannih pusta n"); ("Zapis na disk ne proizvoditsia n"); -1;
}
{("Proizvoditsia zapis BD v fail"); = st; = & ctrl . Nb;
c = (char *) pti; (i = 0; i
putc (* c + +, fl); = (char *) ptr; (k = 0; k
}} load (void)
{i; student * ptr; * pti; * c, d; * fl; ((fl = fopen ("bdd.txt", "r")) == NULL)
{("bdd.txt"); -1;
} (ctrl.nb == 0) ("Baza dannih pusta n"); (ctrl.nb! = 0)
{("Baza dannih v osnovnoi pamiati ne pusta n");
puts ("Proizvodit zagruzku? [y, n]:");
scanf ("% s", & d); (d == 'N' | | d == 'n')
{("Zapros na zagruzku bazi otmenen n"); 1;
}
} ("Proizvoditsia zagruzka bazi dannih n");
pti = & ctrl.nb; = (char *) pti; (i = 0; i
* c + + = getc (fl); = st; = (char *) ptr; (i = 0; i
{((* c = getc (fl))! = EOF) + +;
{(fl); 0;
}
} 0;
} postav (void)
{fam [20]; i; student * ptr; ("--------------------------- - "); (" | Funkcia poiska studenta | "); (" --------------------------- n " ); (ctrl.nb == 0)
{("Spicok zaniatih elementov pust n"); -1;
} ("Vvedite Familiu: n"); ("% s", fam); ((ptr = find (fam)) == 0)
{(" nFamilia ne neidena n");
return -1;
} (ptr == ctrl.bbeg)
{(ctrl.nb == 1)
{("Student Familia | IO | Kurs | Fakultet | Sprcialnost | Kod | Uspevaemost | n "); (" | | | | | | | % 15s | ", ptr-> name); ("% 4s | ", ptr-> inik); ("% 1d | ", ptr-> curs); ("% 5s | ", ptr-> fak); ("% 15s | ", ptr-> jobname); ("% 7s | ", ptr-> job); ("
}
{("Student Familia | IO | Kurs | Fakultet | Sprcialnost | Kod | Uspevaemost | n "); (" | | | | | | | % 15s | ", ptr-> name); ("% 4s | ", ptr-> inik); ("% 1d | ", ptr-> curs); ("% 5s | ", ptr-> fak); ("% 15s | ", ptr-> jobname); ("% 7s | ", ptr-> job); ("
}
}
{(ptr == ctrl.bend)
{("Student Fami...