What is a Pythonic way to pad a numeric string with zeroes to the left, i.e. so the numeric string has a specific length?
For zip codes saved as integers:
>>> a = 6340 >>> b = 90210 >>> print '%05d' % a 06340 >>> print '%05d' % b 90210