Function to precompute the product of proper divisors of a number at it 's corresponding index
void preCompute ( ) { for ( int i = 2 ; i <= 100000 / 2 ; i ++ ) { for ( int j = 2 * i ; j <= 100000 ; j += i ) { ans [ j ] = ( ans [ j ] * i ) % mod ; } } } int productOfProperDivi ( int num ) {