Skip to content

Instantly share code, notes, and snippets.

@sebastianwagner
sebastianwagner / zeropadding.sh
Created June 26, 2013 07:39
Generate list of numbers with zero padding in front. Adjust size of padding according to length of maximum given.
export Y=100; Z=${#Y}; for x in $(seq 1 $Y); do echo $(printf "%0"$Z"d" $x); done