Help me to improve this solution giving TLE (Python 3) using two pointer


#1

class Solution:
# @param A : list of list of integers
# @return an integer

def solve(self, A):
    A=sorted(A ,key=lambda l:l[0])
    start=[]
    end=[]
    count=1
    meeting=[]
    for i in A:
        start.append(i[0])
        end.append(i[1])
    i=0
    j=0
    if(start[0]<end[0]):
        i=1
        j=0
        
    meeting.append(end[0])
    while(i<len(start) and j<len(end)):
        if(start[i]<min(meeting)):
            j=i
            i+=1
            count+=1
            meeting.append(end[j])
        elif(start[i]>=min(meeting)):
            indi=meeting.index(min(meeting))
            meeting[indi]=end[i]
            i+=1
    return(count)