finished naive search