Изменить 'du6/program.c'
This commit is contained in:
parent
67fc6ff6e5
commit
a66b6c185a
@ -14,7 +14,7 @@ int main(){
|
|||||||
for(int i = 0; fgets(inputs[i], 50, stdin) != NULL; i++){
|
for(int i = 0; fgets(inputs[i], 50, stdin) != NULL; i++){
|
||||||
if(i == 0){
|
if(i == 0){
|
||||||
freePlaces = (int) strtol(inputs[0], &ptr, 10);
|
freePlaces = (int) strtol(inputs[0], &ptr, 10);
|
||||||
if(freePlaces < 0 || !isdigit(freePlaces)){
|
if(freePlaces < 0 || !isdigit(freePlaces+'0')){
|
||||||
printf("Nespravny vstup %d\n", freePlaces);
|
printf("Nespravny vstup %d\n", freePlaces);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user