This commit is contained in:
Andrii Hermaniuk 2022-03-27 15:19:33 +02:00
parent 5e2ae48e8a
commit 376a9f16d2

View File

@ -5,15 +5,22 @@
int main(){
int ch=getchar();
char priklad[300];
int count=0;
for(int idx=0;1;idx++){
priklad[idx]=ch;
ch=getchar();
/*if(priklad[idx]!='\n'&&ch){
break;
}*/
if(ch=='\n'){
count++;
}
char *start=priklad, *end=NULL;
ch=getchar();
if(priklad[idx]!='\n'&&ch!='\n'){
break;
}
}
char *start=priklad, *end=NULL;
for(int c=0;c<count;c++){
float num1=strtof(start,&end);
if(end==start){
@ -57,7 +64,7 @@ int main(){
else{
printf("ZLE\n");
}
}
// printf("%.3f\n", vysledok);
return EXIT_SUCCESS;