Create a BIT with size equal to maxElement + 1 ( Extra one is used so that elements can be directly be used as index )
int [ ] BIT = new int [ n + 1 ] ; for ( int i = 1 ; i <= n ; i ++ ) BIT [ i ] = 0 ;