Beefy Boxes and Bandwidth Generously Provided by pair Networks
more useful options
 
PerlMonks  

comment on

( [id://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
http://www.brainbench.com


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

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 making s'mores by the fire in the courtyard of the Monastery: (2)
As of 2024-04-20 03:46 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found