I\'m using sprintf() to get a formatted string of some float numbers with a certain precision. In addition, I wanted to add leading zeros to make all numbers even in length.
keep it simple
echo sprintf("%'06.2f", 32.1);
032.10