Aktualizovat a3/program.c
This commit is contained in:
parent
fa4f2c4df8
commit
02d81e8573
18
a3/program.c
18
a3/program.c
@ -103,7 +103,14 @@ int main()
|
||||
puts("Prijati studenti:");
|
||||
for (int x = 0; x < limit; x++)
|
||||
{
|
||||
printf("%s %s\n", student[x].name, student[x].surname);
|
||||
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)
|
||||
@ -112,7 +119,14 @@ int main()
|
||||
puts("Neprijati studenti:");
|
||||
for (int x = studentsAmount; x < i; x++)
|
||||
{
|
||||
printf("%s %s\n", student[x].name, student[x].surname);
|
||||
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);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Loading…
Reference in New Issue
Block a user