Skip to content

Instantly share code, notes, and snippets.

@daz4126
Created January 20, 2012 14:17
Show Gist options
  • Save daz4126/1647554 to your computer and use it in GitHub Desktop.
Save daz4126/1647554 to your computer and use it in GitHub Desktop.
def play(i)
m=%w(Rock Paper Scissors);m[c=rand(3)]+?,+%w(Draw Win Lose)[((m.index(i)||c-1)-c)%3]
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment