Hello , i want to know how to do a binary search for something ( like lowerbound for a value ) on a binary indexeded tree in (log ( n ) ) . On a segment tree it can be done in Log ( N ) but on binary indexed tree the naive binary search is LOG^2 ( n ) . So does anyone know how to make it in Log(n) ? thanks in advance .