Thread
:
Zero padding
View Single Post
Feb 17th, 2007, 4:48 PM
#
5
Jimbo
Battle Programmer
Join Date: Feb 2006
Location: Bellevue, WA, USA
Posts: 747
Rep Power:
3
I don't know if there's a log function in bash, but if you know the length of the longest one you could use printf %0${maxlen}d $yourNum.
__________________
<insert disclaimer here>
<insert shameless plug for Visual Studio here>
Jimbo
View Public Profile
Find More Posts by Jimbo