Yeah, MrHoo, but what if the user has only entered 3 values? With your code, the blank values will be treated as zeroes and the average for 3 values won't be accurate.
An optimist sees the glass as half full.
A pessimist sees the glass as half empty.
A realist drinks it no matter how much there is.