Complementary and mismatch problem