Question: Write a static method that takes as input an int array and returns a 2 - dimensional int array. The 2 - dim array should
Write a static method that takes as input an int array and returns a dimensional int array. The dim array should have three rows.
The first row should contain the zero integers from the input array.
The second row should contain the negative integers from the input array.
The third row should contain the positive integers from the input array.
The entries in each row should be in the same order that they were in in the input array.
Any one of the three rows could be an empty array even all three of them
Use an enhanced forloop whenever possible.
Step by Step Solution
There are 3 Steps involved in it
1 Expert Approved Answer
Step: 1 Unlock
Question Has Been Solved by an Expert!
Get step-by-step solutions from verified subject matter experts
Step: 2 Unlock
Step: 3 Unlock
