```
 // Find smallest year
 int pastMin=0;
 int currentMin=ontarioBankInfoInt.get(0);
 int currentMinIndex=0;
 int reps=(ontarioBankInfoInt.size()-1)/3;

 for(int x=0; x<=reps; x++){
   for (int i=0; i<ontarioBankInfoInt.size()-1; i++){
        if (ontarioBankInfoInt.get(i)<currentMin){
            if (ontarioBankInfoInt.get(i)>pastMin){
                currentMin = ontarioBankInfoInt.get(i);
                currentMinIndex = i;     
                pastMin = currentMin;
            }//If End
        }//If End       
   }//For End

   //Add other information  
   yearArray.add(currentMin);
 }//For End

```

NOTE: reps is the number of years it needs to find.
The pupose of this code is so search an arrayList for the smallest year then add it to the "yearArray" then it finds the next smallest add adds it to the say array, rinse and repeat until it works through the entire array.

My problem is that it always returns the same year and im not sure why any help?

Thanks