Bit Array Hackerrank Solution Python Programming