Correct checking table algorithm