Изменил(а) на 'du3/program.c'
This commit is contained in:
parent
38fcde55b5
commit
4aef4e93c7
@ -21,18 +21,25 @@ int main(){
|
||||
//float p = 0;
|
||||
while(stop == 0){
|
||||
r = fgets(riadok,LINE_SIZE,stdin);
|
||||
if(feof(stdin)){
|
||||
stop = 1;
|
||||
r2 = atof(riadok);
|
||||
mass[i] = r2;
|
||||
i++;
|
||||
|
||||
}
|
||||
pos++;
|
||||
if (r == NULL || !isdigit(*r) || feof(stdin)) {
|
||||
if (r == NULL || !isdigit(*r)) {
|
||||
//printf("%d", *r);
|
||||
if(*r == 10){
|
||||
stop = 1;
|
||||
}
|
||||
if(feof(stdin)){
|
||||
/*if(feof(stdin)){
|
||||
stop = 1;
|
||||
r2 = atof(riadok);
|
||||
mass[i] = r2;
|
||||
i++;
|
||||
}
|
||||
}*/
|
||||
else{
|
||||
if(pos > 0){
|
||||
printf("Nepodarilo sa nacitat polynom na %d mieste.\n", pos);
|
||||
|
Loading…
Reference in New Issue
Block a user