public class RegularExpressionDemo2 {
public static void main(String[] args) {
Pattern p = Pattern.compile("\\.");
Matcher m = p.matcher("a1b7 @z#");
while (m.find()) {
System.out.println(m.start() + "-------" + m.group());
}
}
}
From the docs, it says the .
symbol prints any character then How come the above program doesn't print any thing.