In a couple of places, it was particularly bad, so I was complaining about it to my boss. About a month later, I found that my boss was the one who wrote that code. It took me several months to fully extract my foot from my mouth...... 8^P

I worked at a place where a colleague (sitting next to the head of IT) said "What ******* **** wrote this ****?", only for said head of IT to say 'Me, I did'. Admittedly, the first thing the head of IT did to get code 'working' was to delete use strict, so it was a fairly valid point to raise.

I have yet to be employed by a business that doesn't dance on the edge; eolving their code base rather than planning and developing. I point out the different solutions available (and their false economies) - but who wants to plan and create something to be proud of when hacking it will do for now.

Personally I always point out any code that I know to be bad, or don't understand. But, this works for me, and should not necessarily be applied to all cases. Sometimes I do re-factor code by hand in order to learn what it is actually doing (which will be different from what others think it does, what the business wanted before and what they want now). I am not frightened of being wrong or highlighting my own lack of knowledge and I am happy to put my foot in my mouth. Either way someone learns something.

Although I agree to some extent that you should have consideration for other people's code, I wouldn't lose sight of the fact that it most likely is not their code - it belongs to the company. Your job is to amend, delete to create new lines of code that will profit the company you are working for. Keep a good perspective of what you are doing and who you are doing it for.

-=( Graq )=-

In reply to Re^2: Consideration for others code by graq
in thread Consideration for others code by tcf03

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



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.