Beefy Boxes and Bandwidth Generously Provided by pair Networks
The stupid question is the question not asked
 
PerlMonks  

comment on

( #3333=superdoc: print w/replies, xml ) Need Help??
This is just a silly little thing that popped up from the mists of my mind. I'm not even sure it's in the right place, but here goes.

The parable of the falling droplet

Or: a silly little mnemonic for record separators

Cue our Hero: a confused Perl coder getting $/ and $\ mixed up again, despite the mnemonics mentioned in perlvar.

Cue The Solution: the Falling Droplet!

Imagine, if you will, a falling droplet of rain. It knows that its purpose in life is to fall down and follow the path of least resistance down to its final destination in a convenient body of water somewhere nearby. Imagine, now, that this droplet encounters an obstacle: a leaning toothpick. It will slide down this toothpick, happily rolling down the obstacle and continuing on its way:

o <--- our brave droplet . . <--- the path our droplet follows . / . / . / ./ <-- the leaning toothpick ./ ./ .../ -------- <-- the ground

Now, take a small mental sidestep and think of input and output: I/O. In between I and O is ... a leaning toothpick. Imagine our brave droplet falling down on this particular toothpick. If the toothpick is leaning towards the right, the droplet will end up on the left of it, if it is leaning to to the left, it will end up on the right of it. Or, if the toothpick leans to the right, the droplet will end up with the I, or input, and consequently, it will end up with the O, or output in the other case.

Cue (finally) The Point: Stick a $ in front of our leaning toothpick, imagine our droplet, and there's our mnemonic:

I/O $/ - droplet falls to left, or I - input record seperator $\ - droplet falls to right, or O - output record separator

Silly, but true.

CU
Robartes- who should really get some sleep now


In reply to The parable of the falling droplet by robartes

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, 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?
    Username:
    Password:

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

    How do I use this? | Other CB clients
    Other Users?
    Others imbibing at the Monastery: (3)
    As of 2020-10-22 03:50 GMT
    Sections?
    Information?
    Find Nodes?
    Leftovers?
      Voting Booth?
      My favourite web site is:












      Results (225 votes). Check out past polls.

      Notices?