Originally posted by r035198x
What happened was, for each for looping it keeps compare with Entry # 1 and 1000 lines of output file. Then loop again for second arraylist Entry # 2 & compare with 1000 lines of output file......
As I have arraylist size about 800 and lines of output file about 1000.
It's supposed to compare current arraylist entry let's assume Entry # 1 with output line # 1 and exit the looping, then repeate again Entry # 2 with output line # 2 and on....
How am I supposed to do about my looping codes....?
Code:
Entry # 1 with output line # 1 - compare - exit looping. Entry # 2 with output line # 2- compare - exit looping... ........ ... at least it stops when there is no more entry in ArrayList eventho there are few lines in output file..
Code:
while ((line = input.readLine()) != null ) // I guess here is the problem
{
for (int i = 0; i <myArrayList.size(); i++) // and this part too.
{
// line = input.readLine();
String[] theline = line.split(" ");
String sdata = theline[0];
String snumber = theline[1];
String svalue = theline[2];
Comment