The same problem in the array and do not use the array when the array is too large to open the memory is too large, the array opened too small to access the bounds, so finesse does not open the array. And later in the writing program when the good habit of __int64 ... Try to do as little as you can to make the most of the wrong things. The correct code is attached below
#include <stdio.h>__int64 Max (__int64 q,__int64 y);intMain () {__int64 a,n,t; scanf ("%i64d",&t); while(t--) { Static__int64 x,s; X=s=0; //printf ("********%i64d****%i64d*******", x,s);scanf"%i64d",&N); while(n--) {scanf ("%i64d",&a); S=s+A; X=Max (x,a); } s=s-x; if((s+1) >=x) printf ("yes\n"); Elseprintf ("no\n"); } return 0;} __int64 Max (__int64 Q,__int64 y) {if(q>y)returnQ; Else returny;}
______________________1205_______________________ can use arrays without arrays ...