x=0
while(x!=4): #当x=!4时,执行循环
print('1. 添加订单')
print('2. 发货')
print('3. 查看订单列表')
print('4. 退出')
x=int(input("输入你的选择:")) #输入选择项
if ① :
y=input("输入订单编号:") #输入订单编号
② #在列表listque中添加订单号
elif x==2:
③ #如果订单列表为空
print("订单列表为空")
else:
print("发货单号:"+listque.pop(0))
elif x==3:
print("等待发货:",listque) #查询列表listque中的订单号
print()
input("运行完毕,请按回车键退出...")
① ② ③
程序描述: 计算正整数 35 到 500之间的所有奇数的和。代码如下:
①
for i in ②
③
print(s)
A=input()
print(A * 5)
>>> world=“world”
>>> print(“hello”,world)
print("请输入3个数:")
x=int(input("x= "))
y=int(input("y= "))
z=int(input("z= "))
temp=0
if x>y:
temp=y
y=x
x=temp
if x>z:
temp=z
z=x
x=temp
If y>z:
temp=z
z=y
y=temp
print(x, y, z)
Dim i As Integer
Dim c As String, s As String, t As String
s = "2021 PYthon": t = ""
For i = 1 To Len(s)
c = Mid(s, i, 1)
If c >= "a" And c <= "z" Then
t = t + c
ElseIf c >= "0" And c <= "9" Then
t = c + t
End If
Next i
Text1.Text = t
执行该程序段后,文本框Text1中显示的内容是( )
n=input(“请输入一个实数:”)
n2= math. floor(float(n))
print(n2)
①在打印机里打印相关的文本或者数字等
②可以用来画图
③在屏幕中输出相应的文本或者数字等
④执行语句print(“python”,3.7)时会出错
print("36+78=",36 +78)
a=87
b=12
print(a,"-",b,"=",a-b)