Python 練習實例77
python 練習實例77
題目:循環輸出列表
程序分析:無。
程序源代碼:
實例:
#!/usr/bin/python # -*- coding: utf-8 -*- if __name__ == '__main__': s = ["man","woman","girl","boy","sister"] for i in range(len(s)): print s[i]
以上實例輸出結果為:
man woman girl boy sister