Untitled

mail@pastecode.io avatar
unknown
python
2 years ago
335 B
4
Indexable
Never
def tasks(n,a,b):

    list_pair = []

    for i in range(len(a)):
        list_pair.append([a[i],b[i]])

    count = 0
    for i in range(len(a)):
        
        tmp = list_pair[i].copy()
        tmp.reverse()
        
        if(tmp[0]!=tmp[1] and tmp in list_pair):
            count += 1
               
    return int(n-count/2)