Beefy Boxes and Bandwidth Generously Provided by pair Networks
good chemistry is complicated,
and a little bit messy -LW
 
PerlMonks  

comment on

( [id://3333]=superdoc: print w/replies, xml ) Need Help??
Very similar to not knowing any better:

Because I am a crappy programmer
If a good programmer thinks things through carefully before starting, then I'm not a good programmer. If a good programmer carefully reviews CPAN for existing implementations before beginning anything new, then I'm really not a good programmer. And if a good programmer implements just the features needed at a given time... well, maybe I should pick another profession.

But that's just a small taste of how bad I am. I'll switch to a slower algorithm to avoid using a temporary variable. I abbreviate variable names to make things fit on one line. I do things in strange ways just because I heard about them or thought "I wonder if you could...", and I use the result in production scripts. I parse HTML and XML with regular expressions. Often. I write code that I know won't work when given filenames with spaces. I'll sometimes keep using code because I'm proud of how little time it took me to write the initial (almost) working version. I'll use C instead of C++ because C compiles faster (so I can get back to gdb faster). I'll use Inline::C for something that would be easier to write as straight C, just because I feel like using perl. I'll spend two hours optimizing code that I plan to run once, where the initial version would have finished in half an hour. I'll rewrite efficient, elegant code because I couldn't understand the algorithm in the original, and end up with a sloppier version of the same algorithm. And then I'll use my inferior version when the time comes to plug it into the rest of the system.


In reply to Re: Confessional: why I wrote bad Perl code. by sfink
in thread Confessional: why I wrote bad Perl code. by vladb

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 goofing around in the Monastery: (3)
As of 2024-04-16 21:10 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found