Grover quantum algorithm is an unstructured search algorithm that can run on a quantum computer with the complexity of O$\sqrt{N}$
N
, and is one of the typical algorithms of quantum computing. Recently, it has served as a routine for pattern-matching tasks. However, the original Grover search algorithm is probabilistic, which is not negligible for problems involving determinism. Besides that, efficient data loading is also a key challenge for the practical applications of the Grover algorithm. Here in this work, we propose a modified pattern-matching scheme with Long’s quantum search algorithm, in which the quantum circuit structure search algorithm requires fewer multi-qubit quantum gates, and can obtain the desired results deterministically. Then, the comparison of the performance of our scheme and the previous algorithms is presented through numerical simulations, indicating our algorithm is feasible with current quantum technologies which is friendly to noisy intermediate-scale quantum (NISQ) devices.