遍历列表
def travel(string):
index = 0
while index < len(string):
letter = string[index]
print letter
index = index + 1
a = “12ww1wwwwww”
print travel(a)
bogon:hhhhh zhouhaijun$ python py_02.py
1
2
w
w
1
w
w
w
w
w
w
原创文章,作者:Maggie-Hunter,如若转载,请注明出处:https://blog.ytso.com/185755.html