PKU 2636. Electrical Outlets. AC
숏코딩 main(i,j,k,sum){for(scanf("%d",&i);i--;printf("%d\n",sum+1))for(sum=0,scanf("%d",&j);j--;scanf("%d",&k),sum+=k-1);} 정상소스 #include main() { int i, j, k, sum=0; scanf("%d",&i); while(i--) { sum=0; scanf("%d",&j); while(j--) { scanf("%d",&k); if(j) k--; sum+=k; } printf("%d\n",sum); } } Run ID User Problem Result Memory Time Language Code Length Submit Time 4433684 jht009 2636 Accepted 204K 0MS..
더보기