Изменить 'du6/program.c'

This commit is contained in:
Oleksandr Hryshchenko 2021-04-16 11:02:18 +00:00
parent 7c15bb5fb2
commit 9306f733d1

View File

@ -45,13 +45,15 @@ int main() {
printf("Prijati studenti:\n");
for(int i = 1; i <= freePlaces; i++){
if(isalpha(inputs[i][0]) || isalpha(inputs[i][1]))
if(inputs[i][0] != '\n' && inputs[i][0] != '\0'){
printf("%s", inputs[i]);
}
}
if(freePlaces < finalPosition) printf("Neprijati studenti:\n");
for(int i = freePlaces; i < finalPosition; i++){
if(isalpha(inputs[i][0]))
if(isalpha(inputs[i][0])){
printf("%s", inputs[i]);
}
}
return 0;