Setup: I have a number that is 10 positions. The number counts up from 0000000000 so that the first number would be 0000000001 followed by 0000000002 and so on. So i know the total number of positions in the string. I want to figure out how to get the total number of zeros i need to append to the beginning of the string. For example, i can look at the ID of an item and see it is "123" and i know that the "name" of the item is "0000000123". So im trying to figure out the best way to get the total number of zeros that need to be added to the beginning of the String to make it 10 characters long in total.
I know that i could use if, else if and go through every single position but i know there has to be a "better" more efficient way. My coding knowledge is sub par so off the top of my head i am not sure where to start. Any help in the right direction would be appreciated. I am also googling for ways but wanted to get this posted here in case anyone wants to give me some pointers.