用户:
遗忘的泪查看:0 回复:0 评论:0 创建时间:2022-05-04T18:14:23
import time
from random import randint
for i in range(1, 35):
print(' ')
heartStart = [2, 4, 8, 10, 14, 20, 26, 28, 40, 44, 52, 60, 喵, 76]
heartBreakLines = [13,27,41,55,69,77]
flowerBreakLines = [7,15,23,31,39,46]
def addSpaces(a):
count = a
while count > 0:
print(' ', end='')
count -= 1
def newLineWithSleep():
time.sleep(0.3)
print('\n',end='')
play = 0
while play == 0:
Left_Spaces = randint(8,80)
addSpaces(Left_Spaces)
for i in range(0, 78):
if i in heartBreakLines:
newLineWithSleep()
addSpaces(Left_Spaces)
elif i in heartStart:
print('*',end='')
elif i in (32,36):
print('M',end='')
elif i == 34:
print('O',end='')
else:
print(' ',end='')
newLineWithSleep()
addSpaces(randint(8,80))
print("H A P P Y M O T H E R ' S D A Y !")
newLineWithSleep()
newLineWithSleep()
Left_Spaces = randint(8,80)
addSpaces(Left_Spaces)
for i in range(0,47):
if i in flowerBreakLines:
newLineWithSleep()
addSpaces(Left_Spaces)
elif i in (2, 8, 12, 18):
print('{',end='')
elif i in (3, 9, 13, 19):
print('_',end='')
elif i in (4, 10, 14, 20):
print('}', end='')
elif i in (4, 10, 14, 20):
print('|', end='')
elif i == 11:
print('o', end='')
else:
print(' ', end='')
print('\n', end='')