The argument that "modern desktops have lots of memory, so it doesn't matter how much we use" is, frankly bollocks.
Yes, your trivial bit of code is unlikely to cause a problem. However, in the real world, memory is finite, and systems are often multi user.
Sloppy habits are not excusable by saying "oh there's load of this resource, so we can waste it".
Usually there's a tradeoff between memory and CPU. If you're too enthusiastic about keeping memory to a minimum, you'll use more CPU. It is most definitely necessary to at least attempt to tidy up after yourself though.
Operating systems are good at cleaning up the mess left by an exiting program, but there's no reason to rely on that.
Sorry, I'll stop ranting. I see that attitude a fair amount, and then I get complaints about how foo server doesn't have enough memory/processor etc.
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: |
| & | | & |
| < | | < |
| > | | > |
| [ | | [ |
| ] | | ] |
Link using PerlMonks shortcuts! What shortcuts can I use for linking?
See Writeup Formatting Tips and other pages linked from there for more info.