Question: Q1:(4 Points) Write a method that computes the average of the neighbors of a table element in the eight directions shown in the following figure

Q1:(4 Points) Write a method that computes the average of the neighbors of a table element in the eight directions shown in the following figure public double neighborAverage (int array1, int row, int column) However, if the element is located at the boundary of the array, only include the neighbors that are in the table. For example, if row and column are both 0, there are only three neighbors. i 1]j - 1 i -1]]i 1]j 1] 1J 1 j] [1j1
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
