Skip to content

Instantly share code, notes, and snippets.

@gioiab
Created April 8, 2016 17:01
Show Gist options
  • Save gioiab/de6d1be1e34659feeec05109ae758975 to your computer and use it in GitHub Desktop.
Save gioiab/de6d1be1e34659feeec05109ae758975 to your computer and use it in GitHub Desktop.
Measurence Engineering Blog - Representing the range of percentage variations from very bad to very good with emojis
def smiley(variation)
if variation < -15
":rage:"
elsif variation >= -15 && variation <= -2
":disappointed:"
elsif variation > -2 && variation < 2
":neutral_face:"
elsif variation >= 2 && variation <= 15
":slightly_smiling_face:"
else
":smile:"
end
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment