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 Revisions

3 of 4
added 131 characters in body
RGS
  • 14.2k
  • 1
  • 62
  • 117

Python 3, 27 bytes

lambda e:"(|)D".find(e[-1])

Try it online!

Because we don't care about the eyes/nose, we can just look at the mouth (the last character) and find its index in a string with all the mouths, ordered from saddest to happiest :)

RGS
  • 14.2k
  • 1
  • 62
  • 117

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