I have a string like
String[] toppings = {"1234", "56789", "123456"};
for each element of toppings I need to check the length, and if it is less than 9, I need to add zeros at the end.
for example consider first element of the array, it is 1234. Its length is 4, so I need to add 5 zeros at the end which looks like "123400000".
similarly I need to do it for all the elements present in toppings.
And finally at the end I need to concat all the vales present in toppings to one string. Means my output must look like String x = "123400000567890000123456000".
Any suggestions?
Thanks,