| 
 | 
вернуться в форумneed help Послано  misele 2 ноя 2010 19:54 someone help me, what's wrong with this code?   #include <stdio.h> #include <math.h>   int main(int argc, char **argv) {     double nums[131072]; /* 256 * 1024 / 2 */     int count = 0;       while (scanf("%lf", nums + count) != EOF)         count++;       while (count) {         count--;         printf("%.4lf\n", sqrt((double)(nums[count])));     }       return 0; }   AC! thanks no help needed anymore.   Edited by author 02.11.2010 22:08 Re: need help Isn't there any "Stack Overflow" error occured? And how can you terminate the input? I have tried "scanf(...)==EOF" and (cin>>...)!=0, but both failed.  |  
  | 
|