print 'L10: {:a^3}'.format(num4) #置中對齊後string長度是3,以'a'填補. print 'L11: {:0>5d}'.format(num4) #變長度為5,向左補0,冒號後只可有 ...
確定! 回上一頁