书上的例子
width = input('please enter width:') priceWidth = 10 itemWidth = width - priceWidth
headerFormat = '%-*s%*s' %标记转换说明符的开始,-表示左对齐,转换后字符串至少应该具有指定宽度 *从值元组中读出
书上的例子
width = input('please enter width:') priceWidth = 10 itemWidth = width - priceWidth
headerFormat = '%-*s%*s' %标记转换说明符的开始,-表示左对齐,转换后字符串至少应该具有指定宽度 *从值元组中读出