Aktualizovat a3/program.c
This commit is contained in:
parent
fa4f2c4df8
commit
02d81e8573
14
a3/program.c
14
a3/program.c
@ -102,18 +102,32 @@ int main()
|
||||
|
||||
puts("Prijati studenti:");
|
||||
for (int x = 0; x < limit; x++)
|
||||
{
|
||||
if (student[x].surname[0] != '\0')
|
||||
{
|
||||
printf("%s %s\n", student[x].name, student[x].surname);
|
||||
}
|
||||
else
|
||||
{
|
||||
printf("%s\n", student[x].name, student[x].surname);
|
||||
}
|
||||
}
|
||||
|
||||
//zacne vypisovat zaznamy neprijatych studentov, tam kde prijati koncia... (studentsAmount premena)
|
||||
if (i > studentsAmount)
|
||||
{
|
||||
puts("Neprijati studenti:");
|
||||
for (int x = studentsAmount; x < i; x++)
|
||||
{
|
||||
if (student[x].surname[0] != '\0')
|
||||
{
|
||||
printf("%s %s\n", student[x].name, student[x].surname);
|
||||
}
|
||||
else
|
||||
{
|
||||
printf("%s\n", student[x].name, student[x].surname);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
return 0;
|
||||
|
||||
Loading…
Reference in New Issue
Block a user