1.strip去除空格
strip函数从头到尾删除字符串中多余的空格
filename = 'budget.csv ’
filename = filename.strip()
filename
‘budget.csv’

2.upper大写转换
upper 函数将所有的字 母转换成大写

filename = ‘budget.csv’
filename.upper()
‘BUDGET.CSV’

3.type查看数据类型
type(‘2011’)
<class ‘str’>
a=[1,2,3]
type(a)
<class ‘list’>