  Quantum computing holds the potential for quantum advantage in optimization
problems, which requires advances in quantum algorithms and hardware
specifications. Adiabatic quantum optimization is conceptually a valid solution
that suffers from limited hardware coherence times. In this sense,
counterdiabatic quantum protocols provide a shortcut to this process, steering
the system along its ground state with fast-changing Hamiltonian. In this work,
we take full advantage of a digitized-counterdiabatic quantum optimization
(DCQO) algorithm to find an optimal solution of the $p$-spin model up to
4-local interactions. We choose a suitable scheduling function and initial
Hamiltonian such that a single-layer quantum circuit suffices to produce a good
ground-state overlap. By further optimizing parameters using variational
methods, we solve with unit accuracy 2-spin, 3-spin, and 4-spin problems for
$100\%$, $93\%$, and $83\%$ of instances, respectively. As a particular case of
the latter, we also solve factorization problems involving 5, 9, and 12 qubits.
Due to the low computational overhead, our compact approach may become a
valuable tool towards quantum advantage in the NISQ era.
