Union Find + Bitmask, 4 ms Java Beats 100%.
Instead of entire hashsets, the limited scope of nums allows us to use two different longs to fit all 100 different nums into the 128 bits of the longs.This all
Instead of entire hashsets, the limited scope of nums allows us to use two different longs to fit all 100 different nums into the 128 bits of the longs. 

This allows us to calculate the intersection of any two rows unique vals by just taking the bitwise and of the masks. From here can just get the bitcount of the bitwise and and determine if it is >= threshold k to see if the intersection is large enough. 



# Code
```java []
class Solution {
    int[] id, sz;
    public int numberOfComponents(int[][] properties, int k) {
        int m = properties.length, n = properties[0].length;
        long[][] propMasks = new long[m][2];
        for(int i = 0; i < m; i++) {
            for(int j = 0; j < n; j++) {
                propMasks[i][properties[i][j]/60] |= (1L << (properties[i][j] % 60));
            }
        }

        id = new int[m];
        sz = new int[m];
        for(int i = 0; i < m; i++) {
            id[i] = i;
            sz[i] = 1;
        }

        for(int r = 0; r < m; r++) {
            for(int i = r+1; i < m; i++) {
                long intersectMask1 = (propMasks[r][0] & propMasks[i][0]), intersectMask2 = (propMasks[r][1] & propMasks[i][1]);
                int intersectSize = Long.bitCount(intersectMask1) + Long.bitCount(intersectMask2);
                if(intersectSize >= k) union(i, r);
            }
        }

        int comp = 0;
        for(int i = 0; i < m; i++) {
            if(find(i) == i) comp++;
        }
        return comp;
    }

    private int find(int p) {
        int root = p;
        while(id[root] != root) root = id[root];

        while(p != root) {
            int next = id[p];
            id[p] = root;
            p = next;
        }

        return root;
    }

    private void union(int p, int q) {
        p = find(p);
        q = find(q);
        if(p == q) return;
        if(sz[p] < sz[q]) {
            id[p] = q;
            sz[q] += sz[p];
        } else {
            id[q] = p;
            sz[p] += sz[q];
        }
    }
}
```
['Bit Manipulation', 'Union Find', 'Java']