AND Reachability DP Concept Doubt

Codeforces Problem 1169E:

I didn’t get the concept at all…how 2D dp[][] bits array is filling up?