Created
August 18, 2018 07:08
-
-
Save KanshuYokoo/99098664473545ae6f82196c77b963c5 to your computer and use it in GitHub Desktop.
java, 0 padding number to string
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// 1000 to 00001000 | |
int myNumber = 1000; | |
String.format("%08d", myNumber); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment