提示:文章写完后,目录可以自动生成,如何生成可参考右边的帮助文档
前言
提示:这里可以添加本文要记录的大概内容:
当他下飞机的那一刻,他那辉煌的一生已经结束
提示:以下是本篇文章正文内容,下面案例可供参考
1.代码
Python代码如下:
# 作者:朱亮
# 开发时间:2024/9/29 19:54
import os
import sys
import time
seconds = 20
def plane_in(postion):
print(' '*postion + ' '*4 +'* *')
print(' '*postion +' '*4 +'* * *')
print(' '*postion +'*' + ' ' + ' * * *')
print(' '*postion +'* * * * * * *')
print(' '*postion +'* * * * * * * *')
print(' '*postion +'* * ' + '[少帅] ' + '* *')
print(' '*postion +'* * * * *')
print(' '*postion +' '*4 +'* * *')
print(' '*postion +' '*4 +'* *')
def plane_out(postion):
print(' '*postion +' '*4 +'* *')
print(' '*postion +' '*4 +'* * *')
print(' '*postion +'*' + ' ' + ' * * *')
print(' '*postion +'* * * * * * *')
print(' '*postion +'* * * * * * * *')
print(' '*postion +'* * ' + '[ ] ' + '* *')
print(' '*postion +'* * * * *')
print(' '*postion +' '*4 +'* * *')
print(' '*postion +' '*4 +'* *')
def plane_out_1(postion):
print(' '*postion +' '*4 +'* *')
print(' '*postion +' '*4 +'* * *')
print(' '*postion +'*' + ' ' + ' * * *')
print(' '*postion +'* * * * * * *')
print(' '*postion +'* * * * * * * *')
print(' '*postion +'* * ' + '* * * ' + '* *')
print(' '*postion +'* [少帅] *')
print(' '*postion +' '*4 +'* * *')
print(' '*postion +' '*4 +'* *')
def plane_out_2(postion):
print(' '*postion +' '*4 +'* *')
print(' '*postion +' '*4 +'* * *')
print(' '*postion +'*' + ' ' + ' * * *')
print(' '*postion +'* * * * * * *')
print(' '*postion +'* * * * * * * *')
print(' '*postion +'* * ' + '* * * ' + '* *')
print(' '*postion +'* * * * ')
print(' '*postion +' '*4 +'[少帅]')
print(' '*postion +' '*4 +'* *')
def plane_out_3(postion):
print(' '*postion +' '*4 +'* *')
print(' '*postion +' '*4 +'* * *')
print(' '*postion +'*' + ' ' + ' * * *')
print(' '*postion +'* * * * * * *')
print(' '*postion +'* * * * * * * *')
print(' '*postion +'* * ' + '* * * ' + '* *')
print(' '*postion +'* * * * ')
print(' ' * postion + ' ' * 4 + '* *')
print(' '*postion +' '*4 +'[少帅]')
def plane_out_leave(postion):
print(' '*postion +' '*4 +'* *')
print(' '*postion +' '*4 +'* * *')
print(' '*postion +'*' + ' ' + ' * * *')
print(' '*postion +'* * * * * * *')
print(' '*postion +'* * * * * * * *')
print(' '*postion +'* * ' + '* * * ' + '* *')
print(' '*postion +'* * * * ')
print(' ' * postion + ' ' * 4 + '* *')
print(' '*postion +' '*4 +'[ ]')
def land():
for i in range(seconds):
os.system('cls')
plane_in(i)
sys.stdout.flush()
time.sleep(0.2)
os.system('cls')
plane_out_1(seconds)
print('\n' + ' '*seconds + '士兵 士兵')
time.sleep(0.5)
os.system('cls')
plane_out_2(seconds)
print('\n' + ' ' * seconds + '士兵 士兵')
time.sleep(0.5)
os.system('cls')
plane_out_3(seconds)
print('\n' + ' ' * seconds + '士兵 士兵')
time.sleep(0.5)
os.system('cls')
for i in range (3):
os.system('cls')
plane_out_leave(seconds)
print('\n'*i + ' '*(seconds) + '士兵 少帅 士兵')
time.sleep(0.5)
land()