Skip to main content
We’ve updated our Terms of Service. A new AI Addendum clarifies how Stack Overflow utilizes AI interactions.
Code Golf

Return to Answer

deleted 65 characters in body
Source Link
Jonathan Allan
  • 115.4k
  • 8
  • 68
  • 293

With some compute effort this might get shorter...

With some compute effort this might get shorter...

added 1195 characters in body
Source Link
Jonathan Allan
  • 115.4k
  • 8
  • 68
  • 293

A monadic Link accepting a list of characters which yields a list of characters.

Try it online!

How?

ỴZ6=ẠƊ€œp$"¢Ọ/’,"642-*+)9(8/17035"ḥⱮ - Link: list of characters, I
Ỵ - split at newline characters
 Z - transpose
 $ - last two links as a monad - i.e. f(X):
 Ɗ€ - for each, last three links as a monad:
 6 - the space character
 = - equals? (vectorises)
 Ạ - all?
 œp - split (X) at truthy indices of (that)
 - (...call the result A) 
 "¢Ọ/’ - base 250 int = 170548 (salt)
 "642-*+)9(8/17035" - list of characters "642-*+)9(8/17035" (domain)
 , - pair -> [salt, domain]
 Ɱ - map across A with:
 ḥ - Jelly's hash function with salt and domain

A monadic Link accepting a list of characters which yields a list of characters.

Try it online!

How?

ỴZ6=ẠƊ€œp$"¢Ọ/’,"642-*+)9(8/17035"ḥⱮ - Link: list of characters, I
Ỵ - split at newline characters
 Z - transpose
 $ - last two links as a monad - i.e. f(X):
 Ɗ€ - for each, last three links as a monad:
 6 - the space character
 = - equals? (vectorises)
 Ạ - all?
 œp - split (X) at truthy indices of (that)
 - (...call the result A) 
 "¢Ọ/’ - base 250 int = 170548 (salt)
 "642-*+)9(8/17035" - list of characters "642-*+)9(8/17035" (domain)
 , - pair -> [salt, domain]
 Ɱ - map across A with:
 ḥ - Jelly's hash function with salt and domain
deleted 23 characters in body
Source Link
Jonathan Allan
  • 115.4k
  • 8
  • 68
  • 293

Jelly, 4436 bytes

With some compute effort this might get shorter...

ỴZ6=ẠƊ€œp$"¢Ọ/’,16ḥⱮμØD;"()+"642-**+)9(8/""¬e_Æẋ*’œ?ị@17035"ḥⱮ

Try it online! Try it online!

Jelly, 44 bytes

With some compute effort this might get shorter...

ỴZ6=ẠƊ€œp$"¢Ọ/’,16ḥⱮμØD;"()+-*/""¬e_Æẋ*’œ?ị@

Try it online!

Jelly, 36 bytes

With some compute effort this might get shorter...

ỴZ6=ẠƊ€œp$"¢Ọ/’,"642-*+)9(8/17035"ḥⱮ

Try it online!

edited body
Source Link
Jonathan Allan
  • 115.4k
  • 8
  • 68
  • 293
Loading
Source Link
Jonathan Allan
  • 115.4k
  • 8
  • 68
  • 293
Loading

AltStyle によって変換されたページ (->オリジナル) /