Re: Factor

Factor: the language, the theory, and the practice.

World Emoji Day

Thursday, July 17, 2025

#calendar

Today, and every July 17th, is World Emoji Day. Kind of amazing that there have already been twelve annual global emoji celebrations! In any event, I was reminded of that by this post:

We have had support in the calendar.holidays vocabulary for defining and computing on holidays, or at least the ones that we have defined already. Turns out, we were missing World Emoji Day!

Well, after adding it, we can now see:

! The last world emoji day (today)
IN: scratchpad today [ world-emoji-day ] year<= .
T{ timestamp
    { year 2025 }
    { month 7 }
    { day 17 }
}

! The next world emoji day!
IN: scratchpad today [ world-emoji-day ] year> .
T{ timestamp
    { year 2026 }
    { month 7 }
    { day 17 }
}

And we can implement the fate checker from the original post by defining our emojis:

CONSTANT: emojis $[
    "๐Ÿ’ฉ๐Ÿคฌ๐Ÿคก๐Ÿ˜ฐ๐Ÿคฎโ˜ ๏ธ๐Ÿ˜ฑ๐Ÿ˜ญ๐Ÿคข๐Ÿ™ƒ๐Ÿ™ˆ๐Ÿ™‰๐Ÿ™Š๐Ÿ‘๐Ÿ‘€๐Ÿ™‚๐Ÿ˜€๐Ÿค—๐Ÿ˜๐Ÿฒ"
    >graphemes [ >string ] map
]

We could choose one at random:

IN: scratchpad emojis random .
"๐Ÿ’ฉ"

Or by rolling dice, and adjusting to zero-based indices:

IN: scratchpad ROLL: 1d20 1 - emojis nth .
"๐Ÿ’ฉ"

Crap.