Recursive check in the right half
return find_mth_bit ( n - 1 , len_right + 1 - ( m - len_left ) , fib ) ; } } void find_mth_bitUtil ( int n , int m ) { int fib [ maxN ] ; calculateFib ( fib , maxN ) ; int ans = find_mth_bit ( n , m , fib ) ; cout << ans << ' ▁ ' ; }