Advertisement
bkit4s0

[SUMTIRIAN] wrong in path

Apr 5th, 2015
227
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Java 0.93 KB | None | 0 0
  1. import java.io.*;
  2.  
  3. class type {
  4.     public static void main(String args[]) throws NumberFormatException,
  5.             IOException {
  6.         // BufferedReader in = new BufferedReader(InputStreamReader(System.in));
  7.         BufferedReader in = new BufferedReader(new InputStreamReader(System.in));
  8.         int t = Integer.parseInt(in.readLine());
  9.         int[] sum;
  10.         //sumleft = sumright = 0;
  11.         while (t-- > 0) {
  12.             int n = Integer.parseInt(in.readLine());
  13.             for (int i = 0; i < n; i++) {
  14.                 String[] a = new String[n + 1];
  15.                 a = in.readLine().split(" ");
  16.                 int[] ar = new int[i + 1];
  17.                 for (int j = 0; j <= i; j++) {
  18.                     ar[j] = Integer.parseInt(a[j]);
  19.                     // System.out.print(ar[j]);
  20.                 }
  21.                 /*if (i == 0) {
  22.                     sumleft = sumright = ar[0];
  23.                 } else {
  24.                     sumleft += ar[0];
  25.                     sumright += ar[i];
  26.                 }*/
  27.                 sum[i]
  28.             }
  29.             /*if (sumleft >= sumright)
  30.                 System.out.println(sumleft);
  31.             else
  32.                 System.out.println(sumright);*/
  33.         }
  34.     }
  35. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement