Beefy Boxes and Bandwidth Generously Provided by pair Networks
P is for Practical

comment on

( #3333=superdoc: print w/replies, xml ) Need Help??

1. Is it just a matter of programming self-confidence, to be able to say "this is finished and correct", without a uneasy sense that there may possibly still be a mistake somewhere.

No. You can and should write tests that verify your claims about your software. If your software beats the tests, you can say "this is finished and correct, as far as my tests go", which is quite an achievement over the state where you just have beliefs about the software. Single-stepping your code in a debugger (small pieces!) also helps in assuring yourself that your software does what you think it does. Code reviews by others are another good thing to increase your confidence. Giving your users a chance to give you feedback, and then listening to them, is helpful, too.

2. What would you advice a "I just want to apply the basics correctly" type of monk like me?

To gain confidence? Read a lot of code, write a lot of code. Try things, don't be afraid. Write tests. Debug your programs, even if you think there are no mistakes. Have others review your code. Have others use your code. Reuse your own code.

3. What are the inherent dangers of cut and paste programming?

Putting things in your program that you probably do not understand to any degree. Nasty side-effects. Reinventing the wheel (cut-and-paste-and-cut-and-paste-and-cut-and-paste-and- ... you get the picture). Not learning to write modules. Not learning to think in terms of modular building blocks. Not learning what programming is all about. Aside from that, of course nearly everybody cuts and pastes. The only difference is that the really good programmers do it only once or twice per item.

Christian Lemburg
Brainbench MVP for Perl

In reply to Re: Some of use just want to know the basics by clemburg
in thread Some of use just want to know the basics by Elias

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, 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, 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.
  • Log In?

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

    How do I use this? | Other CB clients
    Other Users?
    Others chanting in the Monastery: (2)
    As of 2020-05-26 04:50 GMT
    Find Nodes?
      Voting Booth?
      If programming languages were movie genres, Perl would be:

      Results (149 votes). Check out past polls.