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

Re: How do i get the variables to actually get in here....

by wog (Curate)
on Nov 07, 2001 at 02:40 UTC ( [id://123715]=note: print w/replies, xml ) Need Help??


in reply to How do i get the variables to actually get in here....

At least part of your problem seems to be with while (defined(<>)). The <> takes a line from the filehandle, and then you test it for being defined, and (continue to) loop if it is. Unfortunatly, unlike using while(<>) it doesn't actually assign the value into $_. To do that you can use while (defined($_=<>)), but that's exactly equivilent to while(<>).

I would advise that you look at using split, instead of regex for this task. It looks like it probably would be better suited for this data.

Replies are listed 'Best First'.
Re: Re: How do i get the variables to actually get in here....
by krujos (Curate) on Nov 07, 2001 at 02:53 UTC
    Split would be nice and easy but alas my prof has said its "off limits" for this project

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others learning in the Monastery: (6)
As of 2024-04-24 09:57 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found