Advertisement
Guest User

Untitled

a guest
Aug 29th, 2014
182
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.12 KB | None | 0 0
  1. String text = "I said hello, and goodbye."
  2. System.out.println(text.matches("(?i)^.*\bhello\b.*\bgoodbye\b.*$"));
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement