Skip to content

Instantly share code, notes, and snippets.

@8q
Created November 8, 2014 04:25
Show Gist options
  • Star 2 You must be signed in to star a gist
  • Fork 1 You must be signed in to fork a gist
  • Save 8q/a5331c6ef8a205b32125 to your computer and use it in GitHub Desktop.
Save 8q/a5331c6ef8a205b32125 to your computer and use it in GitHub Desktop.
おっぱいそんちくびんびん♪
#coding: UTF-8
'''
Created on 2014/11/08
@author: shirasu
'''
import random
if __name__ == '__main__':
realstr = "おっぱいそんちくびんびん"
strtuple = ("おっ", "ぱい", "そん", "ちく", "びん", "びん")
count = 0
while True:
count += 1
numlist = []
i = 0
while i < 6:
num = random.randint(0,5)
if num in numlist:
continue
numlist.append(num)
i += 1
string = ""
for num in numlist:
string += strtuple[num]
print str(count) + " " + string
if string == realstr:
print "おめでとうございます!",
print "あなたは" + str(count) + "回目に" + realstr + "しました。"
break
print "end"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment