You have to iterate over the array and print each element instead to pass the array to the println method! another way would be to use System.out.println(Arrays.toString(b))
examples can be found in the internet :D (for example: In Java, how can I print an array of ints? - Yahoo! Answers)
Just adding more.
For arrays within arrays you can use Arrays.deepToString(arr). And also toString() calls on each object in an array of Object version.
Oh, and there's nothing weird about the result you reported. It's expected.