Gaming Array Hackerrank Solution In Python For Loop