For each node i with inclusion probability P_i, find the expected number of connected components of the subgraph where two selected nodes are adjacent when gcd > 1, then print E times 100^N mod 1e9+7.
Hard8ProbabilityMathNumber theoryUnion-findNo attempts yetTime limit5sMemory limit512 MB