for (long j = ((i * i) * 2) + 6 * i + 3; j < size; j += p) {
Why do we add p instead of (p-3)/2?
Edit: Ah nevermind. It’s because we want the next value to eliminate to be p^2 + 2p instead of p^2 + p because we want an odd value. And adding p to the index is like adding 2p to the value.