tia_kamakshi
asked on
Creating 5 digit integer value
Hi I am working in Java
I have to create min 5 digit integer value that should start with 1
for example 1 should be 00001
2 should be 00002 etc
00001
00002
...
...
99999
100000
100001
100002
...
...
and if we have a list of above values, I also need to find the earliest no from the list
Please help me with this logic
Many Thanks
I have to create min 5 digit integer value that should start with 1
for example 1 should be 00001
2 should be 00002 etc
00001
00002
...
...
99999
100000
100001
100002
...
...
and if we have a list of above values, I also need to find the earliest no from the list
Please help me with this logic
Many Thanks
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
You can create the numbers stirngs(not integers) by prepending the required number of 'Zeros'.
ASKER
Many Thanks. It works great