In the above implementation we have considered every pair two times so we have to divide every sum2 array element by 2
for i in range ( 1 , max_Element , 1 ) : NEW_LINE INDENT sum2 [ i ] = int ( sum2 [ i ] / 2 ) NEW_LINE DEDENT