class DayClustering {

    public boolean isInside(DayClustering dc) {
        int n = dc.getGroupsCount();
        for (int i = 0; i < n; ++i) {
            int cur = -1;
            for (int j = 0; j < 7; ++j) {
                if (dc.groups[j] == i) {
                    int g = groups[j];
                    if (cur == -1) {
                        cur = g;
                    } else if (g != cur) {
                        return false;
                    }
                }
            }
        }
        return true;
    }

      DayClustering(final int[] groups);

}