Beefy Boxes and Bandwidth Generously Provided by pair Networks
Clear questions and runnable code
get the best and fastest answer
 
PerlMonks  

comment on

( [id://3333]=superdoc: print w/replies, xml ) Need Help??
I'm a consultant. I often talk to people and offer to write scripts for them. It has never yet been an issue. 9 times out of 10, they simply want output parsed and placed into one of the products my company sells or somehow combined with other information to make the output more informative. Week before last, someone asked if I could take the output of something they have and put it into our product. "No problem" quoth I. "What is it you have?" "A perl script," they replied. Of course, I said I'd just re-write it and make it output the way we discussed.

Wow. All I can say was wow. Never before had I seen such a beast as this. To pull apart a file, they have used a `` call to cat with five pipes through grep. They dump this into a plain array. That's just how it starts. I count 35 system pipes through the whole script. I shudder to think how long this must take to run. I had to read through it 7 or 8 times just to understand it. Basically, it appears to be written by somene reasonably proficcient in Unix, but either just learning or not knowing perl.

All I can say is always ask to see the script you think you can re-write in seconds before you offer - else be stuck like me spending Sunday picking it apart with forceps just to see where all the parts are...


In reply to the perils of others' perl - a cautionary tail... by jptxs

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 pondering the Monastery: (4)
As of 2024-04-25 23:28 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found