Search:

Type: Posts; User: pbrockway2

Search: Search took 0.09 seconds.

  1. Re: Affecting Point objects with methods - a beginner's failed attempt

    There's no problem with returning two things. The method is void, so it returns nothing at all!

    Understand that throughout this program you have two points. Just two. And that never changes.
    ...
  2. Re: Affecting Point objects with methods - a beginner's failed attempt

    Both PhHein and myself did address just this I think.

    The question was given here as "An exercise in ch. 3 supplies some code to define two points, send them to a method that trades their (x,y)...
  3. Re: Affecting Point objects with methods - a beginner's failed attempt

    The x/y values of a Point are called the state of the point object.

    As mentioned Java is pass by value. This has to do with variables and their values (not objects and their state). The bottom...
Results 1 to 3 of 3