code: public static void p(int i, Regex r) {
          if (0 == i) {
              System.out.println(i + ": " + r.stringMatched());
          } else {
              System.out.println(i + ": " + r.stringMatched(i));
          }
      }
docs: -- for testing purpose