不知道哪里有问题,求指教。
import re
j=0
temp=input('请输入:’)
result=re.split("#/-",temp)
for i in range(18):
print(result[j],result[j+1],result[j+2])j=j+3
j=2
tempe=0
for i in range(6):
tempe=tempe+result[j]
j=j+3
tempe=tempe/6
print(tempe)
import re
j=0
temp=input('请输入:’)
result=re.split("#/-",temp)
for i in range(18):
print(result[j],result[j+1],result[j+2])j=j+3
j=2
tempe=0
for i in range(6):
tempe=tempe+result[j]
j=j+3
tempe=tempe/6
print(tempe)