可怜的猪头 阅读(195) 评论(0)
[root@localhost /]# cat strduiqi.py
#!/bin/python
mydict={
'name':'zhuliguo',
'age':29,
'student':'student'
}
length=max(map(len,mydict.keys()))
for n in mydict:
    print(n.ljust(length),':',mydict[n])

[root@localhost /]#