private static void findBitSets(int size, int cardinality, BitSetStrategy strategy) {
		if (Thread.currentThread().isInterrupted()) {
			throw new RuntimeException("Timed out.");
		}
		if (size < cardinality) {
			return;
		}
		BitSet b = new BitSet(size);
		if (cardinality == 0) {
			strategy.execute(b);
			return;
		}
		if (size == cardinality) {
			b.set(0, size);
			strategy.execute(b);
			return;
		}
		BitSetCacher cacher = new BitSetCacher();
		findBitSets(size - 1, cardinality, cacher);
		for (BitSet bSub : cacher.cache) {
			b.clear();
			b.or(bSub);
			if (strategy.execute(b)) {
				return;
			}
		}
		cacher.cache.clear();
		findBitSets(size - 1, cardinality - 1, cacher);
		for (BitSet bSub : cacher.cache) {
			b.clear();
			b.or(bSub);
			b.set(size - 1);
			if (strategy.execute(b)) {
				return;
			}
		}
	}