Number of subsets with GCD equal to ' i ' is Math . Pow ( 2 , add ) - 1 - sub
subsets . Add ( i , ( 1 << add ) - 1 - sub ) ; } for ( int i = 0 ; i < m ; i ++ ) Console . Write ( " Number ▁ of ▁ subsets ▁ with ▁ gcd ▁ " + gcd [ i ] + " ▁ is ▁ " + subsets [ gcd [ i ] ] + " STRNEWLINE " ) ; }