DevX Home    Today's Headlines   Articles Archive   Tip Bank   Forums   

Results 1 to 2 of 2
  1. #1
    Join Date
    Jan 2004

    Help with Objects

    ok, I've been trying to make a java program for a high school project. The project is making a Binary Tree class. Now I'm not sure if I'm just writing it all weird but I can add a root node [which would be the top of the tree]. I have a temp variable take the place of either the left subnode or the right subnode depending on if the thing you are adding is less than or greater than. Now everything works up to this one part. I modify t, which it my temp variable, but it doesn't modify that Object it was set = to. Now I am led to believe that all things in Java are byRef and not byVal. Is there a way to fix this? If you need to actually see the code, post so. All of my other classes work, I hope since the teacher wrote most of them.
    "Real programmers don't comment their code because if a program was hard to make it should be hard to understand."

  2. #2
    Join Date
    Dec 2002
    You should probably post the code you are talking about. Need to see the order you do things in etc.
    -- Steven

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
HTML5 Development Center
Latest Articles
Questions? Contact us.
Web Development
Latest Tips
Open Source

   Development Centers

   -- Android Development Center
   -- Cloud Development Project Center
   -- HTML5 Development Center
   -- Windows Mobile Development Center