Beefy Boxes and Bandwidth Generously Provided by pair Networks
We don't bite newbies here... much
 
PerlMonks  

Re: Re: Re: regex issue

by optimist (Beadle)
on Feb 28, 2004 at 00:46 UTC ( [id://332429]=note: print w/replies, xml ) Need Help??


in reply to Re: Re: regex issue
in thread regex issue

Well, then, you need to match on both the name and the age:
$found = 1 if /^\s*\Q$student\E\s+\Q$studentAge\E\s*$/
should do the trick. If no one else ever touches the file, you can get away with eliminating with \s* on either side, but I figure they don't hurt, on the off chance someone brings the data file into an editor at some point.

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://332429]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others imbibing at the Monastery: (4)
As of 2024-04-19 17:33 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found