Search
Finish the method definition below.
Given an array arr, the method sum_extremes should return the sum of the first and the last element of arr.
arr
sum_extremes
Note: If arr does not contain any element, the method should return 0.
0