Question: in java Write a function, getBordersSum(), that takes a 2-dimensional array of integers, row size, and column size as parameters. The function should calculate and

in java
Write a function, getBordersSum(), that takes a 2-dimensional array of integers, row size, and column size as parameters. The function should calculate and return the sum of all integers around the borders of the array as shown in the example below: If the array size is 5x4 and contains the following numbers: Then, the function should sum all the numbers around the array borders (see highlighted cells) and return the sum. In this example, the sum =2+1+0+7+1+4+3+6+7+10+1+8+6+5=61
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
