Great!  That works.  But I was looking to get a little trickier with it.

----------------

If you want to make sure they are alternating like <><><> etc... I would do
this:

$_ = $line;

@syms = m/[<>]/g;
$string = join("", @syms);
if ($strings !~ m/^<(><)*>$/)
{
        ## Scream here!
}

The regular expression:

m/^<(><)*>$/

will ensure that it starts with < and ends with > and anything in between
will be "><" which I think should do the trick. That logic is pretty hairy
though and I could be missing something.

-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
<http://learn.perl.org/> <http://learn.perl.org/first-response>


Reply via email to