public static void tokenize_query(String query, String punctuation) {

        StringBuilder token = new StringBuilder();
        for (int i = 0; i < query.length(); i++) {
            char c = query.charAt(i);
            boolean separator = punctuation.indexOf(c) != -1 || c == ' ';
            if (separator) {
                if (token.length() > 0) {
                    System.out.println(token);
                    token.setLength(0);
                }
                continue;
            }
            token.append(c);
        }

        System.out.println(token);

    }