• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Regular Expresion

 
Naresh Rajan
Ranch Hand
Posts: 45
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
hi,
I am trying to match a string which can contain any digit except 6 as the first charecter. Can anyone please let me know how I do it.

Regards.
 
Jesper de Jong
Java Cowboy
Saloon Keeper
Posts: 15205
36
Android IntelliJ IDE Java Scala Spring
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Have you looked at the API documentation of class java.util.regex.Pattern? It explains how to make a Java regular expression.

What did you try out yourself and how did that work out?
 
Piet Verdriet
Ranch Hand
Posts: 266
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Here's a demo:

Details: http://java.sun.com/j2se/1.5.0/docs/api/java/util/regex/Pattern.html

Good luck.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic