Domanda di colloquio di Google

Find the average of values in an array accounting for integer overflow

Risposta di colloquio

Anonimo

16 ago 2014

Divide each number by length of array, then sum up. If the largest number in array does not overflow, neither will this sum at any point during its computation.

2