How do you left pad an int with zeros when converting to a String in java?
int
String
I\'m basically looking to pad out integers up to 9999
9999
Here is how you can format your string without using DecimalFormat.
DecimalFormat
String.format("%02d", 9)
09
String.format("%03d", 19)
019
String.format("%04d", 119)
0119