#coding:GBK#range函数表示数值范围。s='heisagoodboy'for k in range(len(s)): print s[k],#output h e i s a g o o d b o y