please help me.
package com.codegym.task.task07.task0718;
import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;
import java.util.ArrayList;
/*
Checking the order
*/
public class Solution {
public static void main(String[] args) throws IOException {
//write your code here
BufferedReader f = new BufferedReader(new InputStreamReader(System.in));
ArrayList<String> t = new ArrayList<String>();
for(int i=0; i<10; i++){
t.add(f.readLine());
}
//int a = t.get(0).length();
for(int i=1; i<t.size(); i++){
if(t.get(i--).length() > t.get(i).length()){
//int a = i+1;
System.out.println(t.indexOf(t.get(i)));}
break;
}
//System.out.println(b);
}
}