Results 1 to 3 of 3

Thread: [D@16614e7

  1. #1
    littlebirdpoo is offline Member
    Join Date
    Dec 2011
    Posts
    7
    Rep Power
    0

    Default [D@16614e7

    Hi guys,

    new to array and java, just wondering why when I try to output an array this thing pops up....

    Thanks!

  2. #2
    JosAH's Avatar
    JosAH is offline Moderator
    Join Date
    Sep 2008
    Location
    Voorschoten, the Netherlands
    Posts
    13,525
    Blog Entries
    7
    Rep Power
    20

    Default Re: [D@16614e7

    That's the way arrays print themselves; arrays are kind of stupid when it comes to their text representation. Either print each element yourself or have a look at the Arrays utility class; it has a few methods that can do the job for you.

    kind regards,

    Jos
    cenosillicaphobia: the fear for an empty beer glass

  3. #3
    ozzyman's Avatar
    ozzyman is offline Senior Member
    Join Date
    Mar 2011
    Location
    London, UK
    Posts
    797
    Blog Entries
    2
    Rep Power
    4

    Default Re: [D@16614e7

    You might wish to see this:
    Object (Java 2 Platform SE v1.4.2)

    scroll down to the toString() method to see how those weird outputs are formed.

    (By default, if you try to print an Object the Object.toString() method is called)

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •