Once the matches are discovered, they can be verified with a second test-set of plaintext and ciphertext. If the keysize is "n", this attack uses only formula_4 encryptions (and formula_5 space) in contrast to the naive attack, which needs formula_1 encryptions (but only formula_7 space).