One of the main reasons why computations -- in particular, engineering computations -- take long is that, to be on the safe side, models take into account all possible affecting features, most of which turn out to be not really relevant for the corresponding physical problem. From this viewpoint, it is desirable to find out which inputs are relevant. In general, the problem of checking the input's relevancy is itself NP-hard, which means, crudely speaking, that no feasible algorithm can always solve it. Thus, it is desirable to speed up this checking as much as possible. One possible way to speed up such a checking is to use quantum computing, namely, to use the Deutsch-Josza algorithm. However, this algorithm is just a way to solve this problem, it is not clear whether a more efficient (or even different) quantum algorithm is possible for solving this problem. In this paper, we show that the Deutsch-Josza algorithm is, in effect, the only possible way to use quantum computing for checking which inputs are relevant.