Added default to reduce() method for empty array