TIP: Click on subject to list as thread! ANSI
echo: qedit
to: ALL
from: `DANIEL H. LUECKING`
date: 1998-02-07 01:52:00
subject: Re: regular expressions

From: "Daniel H. Luecking" 
On Fri, 6 Feb 1998, David Marcus wrote:
> Jorj Strumolo  wrote on Thu, 05 Feb 1998 23:34:00 GMT:
> 
> > Recently, as part of a discussion of illegal newsgroup
> > names, I wanted to do a search thru a plain text version
> > of the 22,000 newsgroups on this server, trying to find
> > groups with names over the 14-character unit limit,
[snip]
> > I could do a search for   \.[0-9a-z_+-]#.*      , that is,
> >
> > a dot followed by *1* or more occurrences of 0-9, a-z, _ or +
> > or -, optionally followed by a '.' if the string wasn't the last
> > part of the name.  I couldn't find a way to limit it to *15*
> > or more occurrences of the first range.  Is there one?
> 
> I thought that what you need is "[0-9a-z_+-]++++++++++++++"  -- at least, 
if I
> typed 14 + signs, that is -- but it gave me "incomplete closure". 
[snip]
Yes, this is sort of a logical idea, but that is not how "+" works. The
operators *, #, +, ?, and @ cannot reliably be immediately followed by
themselves or any of the others in this group.
The only way I can see is something like this:
[~.][~.][~.][~.][~.][~.][~.][~.][~.][~.][~.][~.][~.][~.] 
I.e., a string of 15 consecutive character each of which is not a dot.
Alternatively, you could write a macro that searched for any string
delimited by dots, beginning-of-name or end-of-name (I don't know how
your list is delimited) and test the length of the found string (and/or
test for illegal characters, etc.).
Dan Luecking                           Dept. of Mathematical Sciences     
luecking@comp.uark.edu                 University of Arkansas      
http://comp.uark.edu/~luecking/        Fayetteville, AR 72101
---
---------------
* Origin: apana>>>>>fidonet [sawasdi.apana.org.au] (3:800/846.13)

SOURCE: echomail via exec-pc

Email questions or comments to sysop@ipingthereforeiam.com
All parts of this website painstakingly hand-crafted in the U.S.A.!
IPTIA BBS/MUD/Terminal/Game Server List, © 2025 IPTIA Consulting™.