Question: using java neon please point me in the right direction. show all steps 1a. Build (declare, instantiate and initialize with name of age of your

 using java neon please point me in the right direction. show

using java neon please point me in the right direction. show all steps

1a. Build (declare, instantiate and initialize with name of age of your choice) two local Human objects, h1, h2 in a new private buildAndSetTwoHumanObjects method in the ArrayObjectsPassByValue class. Declare another local Human object, h3; instead of instantiating or initializing it, do h3 h2; (h2 is referencing/pointing to where h3 is referencing/pointing). 1b. Comment out the line: h1.changeReferenceOfObjectArray(humanArray); In the main2 method of the ArrayObjectsPassByValue class and replace it with: hAswapContentsOfTwoHumanObjects(h1, h2); C. Implement the new method swapContentsOfTwoHumanObjects in the Human class. Hint: You may have to use a temporary variable, one each for name and age, to store one of the swapping variable e.g: int a =1; int b = 2 int temp- a aa b; b= temp; 1d. Call the buildAndSetTwoHumanObjects and the swapContentsOfTwoHumanObjects from the main2 method of your ArrayObjectsPassByValue class. Print the h1, h2's names and ages before and after the call. 1a. Build (declare, instantiate and initialize with name of age of your choice) two local Human objects, h1, h2 in a new private buildAndSetTwoHumanObjects method in the ArrayObjectsPassByValue class. Declare another local Human object, h3; instead of instantiating or initializing it, do h3 h2; (h2 is referencing/pointing to where h3 is referencing/pointing). 1b. Comment out the line: h1.changeReferenceOfObjectArray(humanArray); In the main2 method of the ArrayObjectsPassByValue class and replace it with: hAswapContentsOfTwoHumanObjects(h1, h2); C. Implement the new method swapContentsOfTwoHumanObjects in the Human class. Hint: You may have to use a temporary variable, one each for name and age, to store one of the swapping variable e.g: int a =1; int b = 2 int temp- a aa b; b= temp; 1d. Call the buildAndSetTwoHumanObjects and the swapContentsOfTwoHumanObjects from the main2 method of your ArrayObjectsPassByValue class. Print the h1, h2's names and ages before and after the call

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!