python---对齐

print '0123'.ljust(20, '-')
print '01234'.ljust(20, '-')
print '012356'.ljust(20, '-')
print '0123567'.ljust(20, '-')

原文地址:https://www.cnblogs.com/helloweworld/p/4098127.html