If n is 3 or the number of set bits in ( n - 1 ) is less than the number of set bits in ( n + 1 )
elif ( n == 3 or set_bits ( n - 1 ) < set_bits ( n + 1 ) ) : NEW_LINE INDENT n -= 1 NEW_LINE DEDENT else : NEW_LINE INDENT n += 1 NEW_LINE DEDENT