• July 7th, 2013, 09:36 AM
amul
if the value is= 13276125962;
then return =13276125973
13276125984
13276125995
13276126006
13276126010
13276126021
13276126032
13276126043
13276126054
13276126065
13276126076
13276126080
13276126091
13276126102
13276126113
13276126124
13276126135
13276126146
13276126150
13276126161
13276126172
13276126183
13276126194
13276126205
13276126216
13276126220
13276126231
13276126242
13276126253
13276126264
13276126275
13276126286
13276126290
13276126301
13276126312
13276126323
13276126334
13276126345
13276126356
13276126360
13276126371
13276126382
13276126393
13276126404
13276126415
13276126426
13276126430
13276126441
13276126452
13276126463
13276126474
13276126485
13276126496
13276126500
13276126511
13276126522
13276126533
13276126544
............
how to do please reply with short example, i am very serious to know this looping system.
• July 7th, 2013, 03:48 PM
angstrem
Every time 1st least significant digit == 6, increment 2nd least significant digit by 1 and set 1st to 0. In all other cases increment both by 1 (or the number by 11).
• July 7th, 2013, 07:49 PM
jps
Quote:

Originally Posted by angstrem
Every time 1st least significant digit == 6, increment 2nd least significant digit by 1 and set 1st to 0. In all other cases increment both by 1 (or the number by 11).

• July 7th, 2013, 07:59 PM
vinceishere
Amul, please explain more on what you are trying to do. There are different ways to loop.
• July 8th, 2013, 01:01 AM
amul
thanks Sir actually i have been done the problem, there is have just add increment value in for loop.
example

long start= 13276125962;
long end= 13276126544;
int increment= 11;
for (long i=start;i<=end;i+=increment){
System.out.println(i);

--- Update ---