Precompute possible errors in blocks
Calculate distance to the next error