Beefy Boxes and Bandwidth Generously Provided by pair Networks
Do you know where your variables are?
 
PerlMonks  

Re: Re: character class problem

by smackdab (Pilgrim)
on Oct 23, 2003 at 05:13 UTC ( #301481=note: print w/replies, xml ) Need Help??


in reply to Re: character class problem
in thread character class problem

I guess then I need to figure out how to get a line read from a file to be "no\nluck" instead of 'no\nluck' Do i have to convert every line after I read it or is there a better way?

Replies are listed 'Best First'.
Re: Re: Re: character class problem
by Roger (Parson) on Oct 23, 2003 at 05:32 UTC
    I am not sure what you are trying to achieve here. Do you want to read the entire file into a single string? If so, try the following:

    use IO::File; use strict; my $f = new IO::File "data", "r" or die "can not open file"; my $data; { local $/; $data = <$f>; } # at here, $data is your entire data file with embedded \n.


Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://301481]
help
Chatterbox?
[Eily]: can't the nodelet be moved though? Maybe you could put one that doesn't change first ("Sections" or "Find Nodes" for example)
[Eily]: "Other Users" seems like a poor choice :P
[Eily]: nope, Nodelet Settings doesn't let you move the XP Nodelet, CSS might
[marinersk]: That would mitigate the distraction/jangle issue, but then the information wouldn't be easy to find when it is populated. Plus, I don't currently see a way to move it, but I'm not done poking around on that point yet.
[marinersk]: Ah, you beat me to it.

How do I use this? | Other CB clients
Other Users?
Others studying the Monastery: (9)
As of 2017-05-29 14:11 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?