static S formatInt(int i, int digits) {
ret padLeft(str(i), '0', digits);
}
Began life as a copy of #2000510
Snippet is not live.
Travelled to 13 computer(s): aoiabmzegqzx, bhatertpkbcr, cbybwowwnfue, ddnzoavkxhuk, gwrvuhgaqvyk, ishqpsrjomds, lpdgvwnxivlt, mqqgnosmbjvj, pyentgdyhuwx, pzhvpgtvlbxg, tslmcundralx, tvejysmllsmz, vouqrxazstgt
No comments. add comment
| Snippet ID: | #2000586 |
| Snippet name: | formatInt - format an int with fixed number of digits |
| Eternal ID of this version: | #2000586/1 |
| Text MD5: | 6bd72ca8c9ccb18626713a4523725eb7 |
| Author: | stefan |
| Category: | javax |
| Type: | New Tinybrain snippet |
| Public (visible to everyone): | Yes |
| Archived (hidden from active list): | No |
| Created/modified: | 2016-07-03 00:46:43 |
| Source code size: | 81 bytes / 3 lines |
| Pitched / IR pitched: | No / No |
| Views / Downloads: | 705 / 464 |
| Referenced in: | -