Beefy Boxes and Bandwidth Generously Provided by pair Networks
laziness, impatience, and hubris
 
PerlMonks  

comment on

( [id://3333]=superdoc: print w/replies, xml ) Need Help??

I believe what you're trying to do is read in a bunch of names from a file, and then have those names available to use as variable names in your code? Is that right?

I remember once trying to do something similar, and eventually convincing myself that it was a struggle to do for a reason. For a start, it's a huuuuge security risk, which makes it bad practice, whether or not this code is going to be used by anyone else.

Perhaps this is an example of an X-Y problem, where you're not telling us what you're trying to achieve in the long run, or why you've chosen this particular method. Or maybe you're just doing it for the hell of it, because it seems like a fun thing to do, or just to find out if it can be done.

If the former, if you can outline your goal and what you've tried so far, I'm sure people will give you great suggestions as to how to proceed. This is the case in which not using 'use strict' may well come back to haunt you, unless you really know what you're doing! If the latter, good on you, and again I'm sure people will help you out.

I know this wasn't much practical help, but I think I'm echoing what was said above by almut, in that the more detail you give, the better and more useful people's answers will be.

I for one am curious about what you want to use this for!

why_bird

update:added link

........
Those are my principles. If you don't like them I have others.
-- Groucho Marx
.......

In reply to Re: Reading and producing variable lists (w/o hashes!) by why_bird
in thread Reading and producing variable lists (w/o hashes!) by bingohighway

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post; it's "PerlMonks-approved HTML":



  • Are you posting in the right place? Check out Where do I post X? to know for sure.
  • Posts may use any of the Perl Monks Approved HTML tags. Currently these include the following:
    <code> <a> <b> <big> <blockquote> <br /> <dd> <dl> <dt> <em> <font> <h1> <h2> <h3> <h4> <h5> <h6> <hr /> <i> <li> <nbsp> <ol> <p> <small> <strike> <strong> <sub> <sup> <table> <td> <th> <tr> <tt> <u> <ul>
  • Snippets of code should be wrapped in <code> tags not <pre> tags. In fact, <pre> tags should generally be avoided. If they must be used, extreme care should be taken to ensure that their contents do not have long lines (<70 chars), in order to prevent horizontal scrolling (and possible janitor intervention).
  • Want more info? How to link or How to display code and escape characters are good places to start.
Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others having a coffee break in the Monastery: (3)
As of 2024-04-20 15:39 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found