标签:pre input 输出 += int while print else 矩阵
lie=int(input(‘lie:‘))
hang=int(input(‘hang:‘))
phang=1
while phang<=hang:
plie=1
if phang==1 or phang==hang:
while plie<=lie:
print(‘*‘,end=‘‘)
plie+=1
while plie<=lie:
if plie==1 or plie==lie:
print(‘*‘,end=‘‘)
else:print(‘ ‘,end=‘‘)
plie+=1
phang+=1
print()
标签:pre input 输出 += int while print else 矩阵
原文地址:http://www.cnblogs.com/xusuns/p/7896279.html