Simple Array Sum Hackerrank Solution Python