Re: Regular Expression
- From: John Gordon <gordon@xxxxxxxxx>
- Date: Wed, 8 Nov 2006 19:18:06 +0000 (UTC)
In <1163012269.707590.302280@xxxxxxxxxxxxxxxxxxxxxxxxxxxx> "Rahul" <ravi.sgn@xxxxxxxxx> writes:
I need a regular expression..
The conditions are as follows...
1. There should not be any blank spaces.
^[^ ]*$
(Note that I interpreted "spaces" literally. If you also wanted to exclude
other space-like characters such as tabs, you'll have to modify this
expression.)
2. Text may or may not contain slashes.
I'm not sure why this condition is even listed. It's okay to have slashes,
but it's also okay not to have them. This condition is meaningless.
--
John Gordon "... What with you being his parents and all,
gordon@xxxxxxxxx I think that you could be trusted not to shaft
him." -- Robert Chang, rec.games.board
.
- Follow-Ups:
- Re: Regular Expression
- From: Rahul
- Re: Regular Expression
- From: Oliver Wong
- Re: Regular Expression
- References:
- Regular Expression
- From: Rahul
- Regular Expression
- Prev by Date: Eclipse: How do I change default junit source template?
- Next by Date: Re: BTree Implementation/Insert Method??
- Previous by thread: Re: Regular Expression
- Next by thread: Re: Regular Expression
- Index(es):
Relevant Pages
|