Beefy Boxes and Bandwidth Generously Provided by pair Networks
Welcome to the Monastery

Comment on

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

Coming back to your general question (and not the specific array vs. hashes-topic):

Have you ever made a coding choice that later you can not rationalize?

That is a common effect. In most SW-development-process-models this is addressed by documentation of your SW-design. By documenting all (important) design choices, you can find out later why you have choosen which way. However programmers tend to like coding and to dislike documentation ... thus the reasons for a decision are often forgotten. So in the real world this approach is less usefull than in theory.

When I code, I often just "try if things work", without thinking too much which is the best way (unless I estimate that performance (runtime, memory) will be critical). Then later I often encounter the situation that I wonder why I didn't use another approach. The only rationalization is "it seemed to work that way before". However there is nothing wrong with that approach. Modern SW-development-methodology even encourages it: if the old decision is not good (enough), just do a refactoring .

So the answer to your question is: Yes. However that is nothing uncommon, and nothing to worry too much.


In reply to Re: An irrational coding choice found by Ratazong
in thread An irrational coding choice found by Lady_Aleena

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!
  • 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
  • Outside of code tags, you may need to use entities for some characters:
            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 making s'mores by the fire in the courtyard of the Monastery: (5)
    As of 2015-04-02 07:16 GMT
    Find Nodes?
      Voting Booth?

      Who makes your decisions?

      Results (62 votes), past polls