Why does it show error


#1

THIS IS MY CODE IT SHOWS TLE PLS TELL WHY
int Solution::solve(vector &A, vector &B, vector &C)
{
int i=0,j=0,k=0;
int maxmin= INT_MAX;
while(i<=A.size()-1 && j<B.size()-1 && k<C.size()-1)
{
maxmin=abs(max(A[i],max(B[j],C[k]))-min(A[i],min(B[j],C[k])));

    if(A[i]==min(A[i],min(B[j],C[k])))
    i++;
    else if(B[i]==min(A[i],min(B[j],C[k])))
    j++;
    else if(C[i]==min(A[i],min(B[j],C[k])))
    k++;
}
return maxmin;

}