Refactor stringhe, main, cerca