Hi Discipulus,

I like your solution because it's doing the work using Perl code. I do not think that is is a great idea to use several different modules to solve such a simple problem, especially for a beginner probably learning the art of programming. I think it is better for a beginner to actually learn coding such simple algorithms before using ready-made solutions from modules. (I suspect that some monks will probably disagree with me and say that you shouldn't reinvent the wheel, but I insist that the most essential quality of a programmer is to be able to understand a problem and to implement things with no ready-made crutches.)

I have seen too many self-styled Web developers just using intensively Laravel or Symphony, but more or less unable to write five lines of consistent PHP code. IMHO, it is important to learn doing the things by yourself before you use some extra libraries doing the hard work for you.


In reply to Re^2: Sum group of numbers and display each number is on its own line -- plain way by Laurent_R
in thread Dice roll chances by Anonymous Monk

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.