40. (D) In Implementation 1, the first element assigned is prod[1], and it multiplies arr[1] by prod[0], which was initialized to 1. To fix this implementation, you need a statement preceding the loop, which correctly assigns prod[0]: prod[0]=arr[0];