python dfs recursion
```\ndef cscore(a,b):\n    ans=0\n    for i in range(len(a)):\n        if a[i]==b[i]:\n            ans+=1\n    return ans    \ndef function(students,mentors,n,s
```\ndef cscore(a,b):\n    ans=0\n    for i in range(len(a)):\n        if a[i]==b[i]:\n            ans+=1\n    return ans    \ndef function(students,mentors,n,score,ans,visited):\n    \n    if n==0:\n        ans.append(score)\n        return\n    for i in range(len(students)):\n        if not visited[i]:\n            visited[i]=True\n            function(students,mentors,n-1,score+cscore(students[n-1],mentors[i]),ans,visited)\n            visited[i]=False\nclass Solution:\n    def maxCompatibilitySum(self, students: List[List[int]], mentors: List[List[int]]) -> int:\n        ans=[]\n        score=0\n        n=len(students)\n        visited=[False]*(len(students))\n        function(students,mentors,n,score,ans,visited)\n        #print(ans)\n        return(max(ans))
['Depth-First Search', 'Python']