halubilo.social
  • Communities
  • Create Post
  • Create Community
  • heart
    Support Lemmy
  • search
    Search
  • Login
  • Sign Up
@[email protected] to Programmer [email protected] •
edit-2
11 months ago

Oh boy what a beautiful regex. I'm sure it does something logical and easy to understand.

lemmy.world

message-square
80
fedilink
336

Oh boy what a beautiful regex. I'm sure it does something logical and easy to understand.

lemmy.world

@[email protected] to Programmer [email protected] •
edit-2
11 months ago
message-square
80
fedilink

^.?$|^(..+?)\1+$

<answer>

Matches strings of any character repeated a non-prime number of times

https://www.youtube.com/watch?v=5vbk0TwkokM

  • 🇦🇺𝕄𝕦𝕟𝕥𝕖𝕕𝕔𝕣𝕠𝕔𝕠𝕕𝕚𝕝𝕖
    link
    fedilink
    English
    18•11 months ago

    Just waiting for the oppertunity to hide this in prod.

Programmer [email protected]

[email protected]

Subscribe from Remote Instance

Create a post
You are not logged in. However you can subscribe from another Fediverse account, for example Lemmy or Mastodon. To do this, paste the following into the search field of your instance: [email protected]

Post funny things about programming here! (Or just rant about your favourite programming language.)

Rules:

  • Posts must be relevant to programming, programmers, or computer science.
  • No NSFW content.
  • Jokes must be in good taste. No hate speech, bigotry, etc.
  • 5 users / day
  • 343 users / week
  • 2.25K users / month
  • 7.8K users / 6 months
  • 38.3K subscribers
  • 1.86K Posts
  • 39.1K Comments
  • Modlog
  • mods:
  • @[email protected]
  • @[email protected]
  • BE: 0.19.3
  • Modlog
  • Instances
  • Docs
  • Code
  • join-lemmy.org