Beefy Boxes and Bandwidth Generously Provided by pair Networks
Do you know where your variables are?
 
PerlMonks  

Perl Secret Operator Emojis

by eyepopslikeamosquito (Archbishop)
on Nov 05, 2023 at 05:40 UTC ( [id://11155383]=perlmeditation: print w/replies, xml ) Need Help??

To continue my learning of Unicode Emojis, I thought it'd be fun to try to concoct emojis for some of Perl's famous secret operators.

Here's what I've come up with so far:

NameOperatorEmojiNotes
Diamond<>💎nicknamed by Geneva Wall circa 1994
Spaceship<=>🚀nicknamed by Heidi Wall and Randal L. Schwartz (merlyn 🪄) circa 1994
Saturn*=( )=🪐scalar/list context
Kite~~<>🪁a single line of input
Babycart@{[ ]}👒🛷list interpolation, invented by Larry 🧱 (TimToady) circa 1994

*Note: I have chosen not to use the taboo name for this secret operator used at perlsecret

I found this exercise to be surprisingly challenging. Unable to find an emoji for BooK's quirky Babycart (or a pram), I opted instead to look for emojis that do justice to the LanX's imaginative suggestion of Mexican Sledge -- because he visualizes @{[ ]} as a guy with sombrero dragging a sled(ge) uphill.

Please feel free to suggest alternative Unicode emojis for the secret operators above and to concoct emojis for other secret operators.

See Also

Updated: removed duplicate Mexican Sledge reference; added attribution to Heidi Wall; added Wall emoji for Larry and magic wand emoji for merlyn.

👁️🍾👍🦟

Replies are listed 'Best First'.
Re: Perl Secret Operator Emojis
by kcott (Archbishop) on Nov 06, 2023 at 11:49 UTC

    G'day 👁️🍾👍🦟,

    ++ Thanks for providing some hours of entertainment.

    I went through perlsecret and covered a fair swag of what's there. Quite a few have: "Alternate nicknames: ..." which provided names that were easier to represent as emoji; I've shown these as "aka: ...".

    There are also quite a few examples of modifying emoji and combining two into one. The "Flaming X-Wing" is highly contrived to show all of these types of modifications in one; I've provided a better example which is just a single character. Here's a quick rundown:

    • VARIATION SELECTOR-16 — change default textual rendering to emoji rendering.
    • EMOJI MODIFIER FITZPATRICK TYPE-N — change skin tone.
    • ZERO WIDTH JOINER — combine two emoji into one.

    I was concerned about wrapping in the table; the columns are a little squashed to hopefully prevent this.

    NameOp☺️C'pointUnicode NameNotes
    Diamond <> 💎 U+1F48E GEM STONE No change
    Spaceship <=> 🛸 U+1F6F8 FLYING SAUCER Preferred over 🚀 U+1F680 ROCKET
    (mentioned by ++karlgoethebier)
    Venus 0+ ♀️ U+2642
    U+FE0F
    FEMALE SIGN
    VARIATION SELECTOR-16
    = astrological symbol for Venus
    Baby cart @{[ ]} 🐢 U+1F422 TURTLE aka: ..., "turtle"
    Bang bang !! ‼️ U+203C
    U+FE0F
    DOUBLE EXCLAMATION MARK
    VARIATION SELECTOR-16
    It's already an emoji
    Eskimo greeting }{ 🦋 U+1F98B BUTTERFLY aka: "butterfly"
    Maori farewell -M5; 👋🏾 U+1F44B
    U+1F3FE
    WAVING HAND SIGN
    EMOJI MODIFIER FITZPATRICK TYPE-5
    Skin tone from "NZ Coat of Arms"
    Inchworm ~~ 🪱 U+1FAB1 WORM  
    Space station -+- 🛰️ U+1F6F0
    U+FE0F
    SATELLITE
    VARIATION SELECTOR-16
     
    ������ =( )= 🪐 U+1FA90 RINGED PLANET aka: "Saturn"
    Flaming X-Wing =<>=~ 👨🏽‍✈️ U+1F468
    U+1F3FD
    U+200D
    U+2708
    U+FE0F
    MAN
    EMOJI MODIFIER FITZPATRICK TYPE-4
    ZERO WIDTH JOINER
    AIRPLANE
    VARIATION SELECTOR-16
    Example of multiple components
    From doco:
    "... the X-Wing can have a pilot!"
    Possibly better:
    🎆 U+1F386 FIREWORKS
    Kite ~~<> 🪁 U+1FA81 KITE No change
    Enterprise ( )x!! 🐌 U+1F40C SNAIL aka: ..., "snail"

    Although I've shown codepoints (C'point column) listed separately; they should be written without spaces. For example, The Flaming X-Wing (pilot) as HTML entity references:
    &#128104;&#127997;&#8205;&#9992;&#65039;.

    — Ken

Re: Perl Secret Operator Emojis
by karlgoethebier (Abbot) on Nov 05, 2023 at 16:30 UTC

    I think <=> looks more like 🛸 - a flying saucer.

    «The Crux of the Biscuit is the Apostrophe»

Re: Perl Secret Operator Emojis
by LanX (Saint) on Nov 06, 2023 at 00:41 UTC
    I prefer wristwatch ⌚° over Saturn 🪐

    And I think it also plays better with the counting metaphor (length of list)

    I remember us having a longer discussion about alternative interpretations for =()= , listing (sic ;) many options, but I can't find it anymore. About 15 years ago...

    Cheers Rolf
    (addicted to the Perl Programming Language :)
    see Wikisyntax for the Monastery

    Update

    °) the supposed name was "Rolex operator" (thanks to Discipulus for finding the thread)

      Hello LanX

      > but I can't find it anymore..

      it was a poll

      L*

      There are no rules, there are no thumbs..
      Reinvent the wheel, then learn The Wheel; may be one day you reinvent one of THE WHEELS.
        Thanks, not sure why I couldn't find it.

        Not a real "Poll" tho, I was young and ambitious and wanted to improvise one with the Reputation system.

        There were a lot of interesting suggestions, with even more interesting emojis... :)

        And now I remember we called it Rolex and not wristwatch ⌚.

        While Rolex might come easier from the lips, it's a bit unfortunate that it's a commercial brand.

        Cheers Rolf
        (addicted to the Perl Programming Language :)
        see Wikisyntax for the Monastery

Re: Perl Secret Operator Emojis ($A++)
by eyepopslikeamosquito (Archbishop) on Nov 08, 2023 at 03:48 UTC

    $A++ is a deformation of "A plus" which is itself the common way to shorten "A plus tard". It is for the French what "see you" is to "see you later" in English.

    -- stefp

    And for the Australians, what "see ya" is to "see ya later mate" (or "see ya later cobber").

    -- eyepopslikeamosquito

    Like the JAPH, the $A++ is just an arbitrary canonical program. An $A++ does not emit anything, it just increments the variable $A. Traditionally, it's a parting word to end an email with, so it should be short.

    The first $A++ was composed by BooK 📕 on Friday Oct 15 1999:

    $A = eval q.@{[.."0,"x$A.qq|0]}|
    Not bad for a first attempt! A bit more interesting than the first JAPH. ;-)

    As indicated above (and in more detail at The Lighter Side of Perl Culture (Part III): Obfu) the $A++ has a long and proud tradition in Obfuscated Perl culture, and so is definitely worthy of an emoji. Here are my first attempts:

    💵🅰✝️✝️

    💲🅰

    🤑🅰✝️✝️

    Improvements welcome!

    👁️🍾👍🦟

      Since $A++ is typically used as a "see you later" sign-off, I suppose you might try adding some sort of farewell emoji; the only one I could find was a waving hand.

      💲🅰👋

      BTW, I had no luck rendering flag emojis, presumably because most platforms understandably don't want to become embroiled in online political brawls (e.g. displaying of country flags while wars are raging). See also: Flag emojis not rendering (SO).

      Update: Final version with kcott's improved farewell emoji:

      💲🅰🙋

      Further update: With symbolic plus symbol (suggested by kcott here):

      💲🅰⁺⁺🙋

      👁️🍾👍🦟
        "... some sort of farewell emoji; the only one I could find was a waving hand."

        How about 🙋 U+1F64B HAPPY PERSON RAISING ONE HAND?

        You can also customise. Some examples:
        🙋‍♂️ 1F64B 200D 2642 FE0F ♂️ [sex]
        🙋🏾 1F64B 1F3FE [skin tone]
        🙋🏼‍♀️ 1F64B 1F3FC 200D 2640 FE0F ♀️ [skin tone & sex]

        And, no doubt, with your (much better than my) Segoe UI Emoji font, you could make them young, old, bald, red-headed, bearded, bespectacled, and so on. ☺️

        "I had no luck rendering flag emojis"

        Are you using U+1F1E6 REGIONAL INDICATOR SYMBOL LETTER A through U+1F1FF REGIONAL INDICATOR SYMBOL LETTER Z?

        Some are obvious (like AU for Australia):
        🇦 + 🇺 = 🇦🇺

        Some are less obvious (United Kingdom needs GB for Great Britain):
        🇬 + 🇧 = 🇬🇧

        They don't have to be country flags:
        🇺 + 🇳 = 🇺🇳

        — Ken

Re: Perl Secret Operator Emojis
by eyepopslikeamosquito (Archbishop) on Nov 06, 2023 at 11:17 UTC

    Getting more ambitious, an emoji for the Perl Monks web site?

    🦪🧘

    ... or JAPH (Just Another Perl Hacker):

    ⚖️🦪🧑‍💻

    Improvements welcome!

    👁️🍾👍🦟
      "Improvements welcome!"

      You can join 👨 (U+1F468 MAN) and 💻 (U+1F4BB PERSONAL COMPUTER) with U+200D ZERO WIDTH JOINER giving 👨‍💻.

      — Ken

        You can join (U+1F468 MAN) and (U+1F4BB PERSONAL COMPUTER) with U+200D ZERO WIDTH JOINER

        AFAICT, my emoji is essentially the same as yours, except instead of:

        U+1F468 MAN (adult | man)

        I chose:

        U+1F9D1 ADULT GENDER-NEUTRAL (adult | gender-neutral | person | unspecified gender)

        because it seemed more gender inclusive.

        👁️🍾👍🦟
Re: Perl Secret Operator Emojis
by cavac (Parson) on Nov 21, 2023 at 15:46 UTC

    While technically not secret (but very underused, though i love it to use in example code) is the yadayada operator ... the ultimate "please fill in the blanks" sign. I'd assign it the Unicode shrug 🤷

    Hmm, maybe someone could come up with an Acme:: source code filter that makes Perl accept emojis for all these operators...

    PerlMonks XP is useless? Not anymore: XPD - Do more with your PerlMonks XP

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: perlmeditation [id://11155383]
Approved by Athanasius
Front-paged by kcott
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others imbibing at the Monastery: (2)
As of 2024-06-25 09:25 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found

    Notices?
    erzuuli‥ 🛈The London Perl and Raku Workshop takes place on 26th Oct 2024. If your company depends on Perl, please consider sponsoring and/or attending.