pad sequential filenames so alphabetical order
matches numerical order. It automatically
determines the necessary integer field width, treats
filenames with different prefixes or suffixes
separately, removes redundant padding, and is
reasonably efficient, even for thousands of names.