Skip to content

Instantly share code, notes, and snippets.

@shunsugai
Last active March 12, 2016 00:47
Show Gist options
  • Save shunsugai/432e16f85b16800daabc to your computer and use it in GitHub Desktop.
Save shunsugai/432e16f85b16800daabc to your computer and use it in GitHub Desktop.
def zundoko(history = [])
return puts 'キ・ヨ・シ!' if history == ['ズン', 'ズン', 'ズン', 'ズン', 'ドコ']
zundoko(history.last(4) << ['ズン', 'ドコ'].sample.tap { |x| puts x })
end
zundoko
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment