Java Arrays convert two dimensional array to String for debug

Description

Java Arrays convert two dimensional array to String for debug

import java.util.Arrays;

public class Main {
  public static void main(String args[]) {
    double d [][]= {
        {0.51, 0.21,  0.23, 0.34},//from w  ww . j  a v  a2 s  .co m
        {0.52, 1.12,  0.53, 0.84},
        {0.53, 0.73,  0.43},
        {0.53, 0.73,  0.43},
        {0.53, 0.73,  0.43},
        {0.53, 0.73,  0.43},
        {0.54, 0.74},
        {0.55},
    };
    System.out.println(Arrays.deepToString(d));
  }
}



PreviousNext

Related