Written by #August 24, 2016March 2, 2017 STRING ||| Adding leading zeros Stuffing leading zeroes: printf %09d $VALUE Adding trailing spaces: printf %-9s $VALUE Advertisements Share this:TwitterFacebookLike this:Like Loading... Related Leave a Reply Cancel reply Enter your comment here... Please log in using one of these methods to post your comment: Email (required) (Address never made public) Name (required) Website You are commenting using your WordPress.com account. ( Log Out / Change ) You are commenting using your Google account. ( Log Out / Change ) You are commenting using your Twitter account. ( Log Out / Change ) You are commenting using your Facebook account. ( Log Out / Change ) Cancel Connecting to %s Notify me of new comments via email. Notify me of new posts via email.