#!/usr/bin/env python
# -*- coding: utf-8 -*-
'''
task.py
创建一个tuple,顺序包含0 - 9这10个数。
'''
# the first
t = (0, 1, 2, 3, 4, 5, 6, 7, 8, 9)
print t
# second range函数方法:支持3个参数,start其实元素,stop结束元素,元素之间的间隔(默认为0)
T = tuple(x for x in range(0,10))
print T
#!/usr/bin/env python
# -*- coding: utf-8 -*-
'''
task.py
创建一个tuple,顺序包含0 - 9这10个数。
'''
# the first
t = (0, 1, 2, 3, 4, 5, 6, 7, 8, 9)
print t
# second
T = tuple(x for x in range(0,10))
print T