Logarithm | Python 3 program to find log ( n ) using Recursion ; Driver code
def Log2n ( n ) : NEW_LINE INDENT return 1 + Log2n ( n / 2 ) if ( n > 1 ) else 0 NEW_LINE DEDENT n = 32 NEW_LINE print ( Log2n ( n ) ) NEW_LINE