4.2.3
x=0
while x<5
Print(“The count:”,x)
x=x+1
Print(“end”)
执行结果为：
The count:0
The count:1
The count:2
The count:3
The count:4
end
x = 0
While 2:
Print(“The count:”,x)
x = x + 1
Print(“end”)
4.4
a = int(input(“The first num:”)) #输入第一个正整数
b = int(input(“The second num:”)) #输入第二个正整数
x1 = a
x2 = b
if x1<x2:
t = x1
x1 = x2
x2 = t
s = x1 % x2
while s!=0
x1 = x2
x2 = s
s= x1 % x2
print(a,"和",b,"的最大公约数:" x2)
4.2.2
for letter in ‘hello’
print(‘当前字母为：’,letter)
Book = [‘Java’,’C#’,’Python’]
for it in Book
print(‘当前元素为：’,it)
  print(“over”)
4.5
Book = [‘Java’,’C#’,’Python’]
for i in range(len(Book))
print(‘当前元素为：’, Book[i])
  print(“over”)
4.2.3
for i in range(1,10)：
      for j in range(1,i+1)
           print(i,’*’,j,’=’,i*j,’\t’,end=””)  #end=””作用是不换行
      print(””)  #换行
4.3.1
i=1
while i
     i += 1
     if i > 3：
          break
     print(i,””)
4.3.2
i=1
while i <10
     i += 1
     if i % 2 >0:
          continue
     print(i,””)
4.3.3
a = 66
b = 200

if b > a:
pass
else
b = 230
print(a,””,b)





